1 |
commit: 3a1569e99ba430e929e1367ea68f13184f015ab8 |
2 |
Author: Ian Stakenvicius <axs <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Aug 15 21:09:17 2018 +0000 |
4 |
Commit: Ian Stakenvicius <axs <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Aug 15 21:09:17 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=3a1569e9 |
7 |
|
8 |
thunderbird: attempt to fix setupterm issues by patch |
9 |
|
10 |
The python lib 'blessings' is what requires setupterm, and it |
11 |
seems to be semi-optional based on the code that loads it; this |
12 |
commit drops the need for blessings by forcing a return of |
13 |
NullTerminal instead of only doing so when blessings.Terminal throws |
14 |
an exception. |
15 |
|
16 |
Note - this is a debug commit, the final fix will involve properly |
17 |
running down why the exception isn't caught, or how to force |
18 |
the disable_colors setting to ensure NullTerminal is always used. |
19 |
|
20 |
mail-client/thunderbird/files/fix-setupterm.patch | 22 ++++++++++++++++++++++ |
21 |
mail-client/thunderbird/thunderbird-60.0-r1.ebuild | 1 + |
22 |
2 files changed, 23 insertions(+) |
23 |
|
24 |
diff --git a/mail-client/thunderbird/files/fix-setupterm.patch b/mail-client/thunderbird/files/fix-setupterm.patch |
25 |
new file mode 100644 |
26 |
index 0000000..0928ca0 |
27 |
--- /dev/null |
28 |
+++ b/mail-client/thunderbird/files/fix-setupterm.patch |
29 |
@@ -0,0 +1,22 @@ |
30 |
+--- a/python/mozterm/mozterm/terminal.py 2018-07-31 14:21:02.000000000 -0400 |
31 |
++++ b/python/mozterm/mozterm/terminal.py 2018-08-15 17:00:45.540515437 -0400 |
32 |
+@@ -32,18 +32,9 @@ |
33 |
+ return '' |
34 |
+ return args[0] |
35 |
+ |
36 |
+ def __getattr__(self, attr): |
37 |
+ return self.NullCallableString() |
38 |
+ |
39 |
+ |
40 |
+ def Terminal(raises=False, disable_styling=False, **kwargs): |
41 |
+- if disable_styling: |
42 |
+- return NullTerminal(**kwargs) |
43 |
+- |
44 |
+- try: |
45 |
+- import blessings |
46 |
+- except Exception: |
47 |
+- if raises: |
48 |
+- raise |
49 |
+- return NullTerminal(**kwargs) |
50 |
+- return blessings.Terminal(**kwargs) |
51 |
++ return NullTerminal(**kwargs) |
52 |
|
53 |
diff --git a/mail-client/thunderbird/thunderbird-60.0-r1.ebuild b/mail-client/thunderbird/thunderbird-60.0-r1.ebuild |
54 |
index 6b28658..f87cfb2 100644 |
55 |
--- a/mail-client/thunderbird/thunderbird-60.0-r1.ebuild |
56 |
+++ b/mail-client/thunderbird/thunderbird-60.0-r1.ebuild |
57 |
@@ -112,6 +112,7 @@ src_prepare() { |
58 |
"${WORKDIR}"/firefox/2005_ffmpeg4.patch \ |
59 |
|| die |
60 |
eapply "${WORKDIR}/firefox" |
61 |
+ eapply "${FILESDIR}"/fix-setupterm.patch |
62 |
|
63 |
# Ensure that are plugins dir is enabled as default |
64 |
sed -i -e "s:/usr/lib/mozilla/plugins:/usr/lib/nsbrowser/plugins:" \ |