[oe-commits] Leonardo Sandoval : terminal.py: Allow devshell/ menuconfig on recent gnome-terminal

git at git.openembedded.org git at git.openembedded.org
Fri Jun 26 13:09:00 UTC 2015


Module: openembedded-core.git
Branch: master-next
Commit: ec79684a1eb594099d342a416ba3f5ad0b342a53
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=ec79684a1eb594099d342a416ba3f5ad0b342a53

Author: Leonardo Sandoval <leonardo.sandoval.gonzalez at linux.intel.com>
Date:   Tue Jun  2 14:54:27 2015 -0500

terminal.py: Allow devshell/menuconfig on recent gnome-terminal

Recent versions of gnome-terminal does not support non-UTF8 charset:
https://bugzilla.gnome.org/show_bug.cgi?id=732127 as a result, devshell and
menuconfig tasks silently hang  (error found on trace log of 'strace -f -v
-s 8192 -e write=2 bitbake -c devshell quilt-native': "Non UTF-8 locale
(ANSI_X3.4-1968) is not supported!"). As a workaround, clearing the LC_ALL
environment variable so it uses the locale. Once fixed on the gnome-terminal
project, this should be removed.

Tested on gnome-terminal versions:

       GNOME Terminal 3.4.1.1
       GNOME Terminal 3.14.2 (Default on Ubuntu 15.04)

[YOCTO #7791]

Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez at linux.intel.com>
Signed-off-by: Ross Burton <ross.burton at intel.com>

---

 meta/lib/oe/terminal.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/meta/lib/oe/terminal.py b/meta/lib/oe/terminal.py
index 4f5c611..52a8913 100644
--- a/meta/lib/oe/terminal.py
+++ b/meta/lib/oe/terminal.py
@@ -57,6 +57,12 @@ class Gnome(XTerminal):
     priority = 2
 
     def __init__(self, sh_cmd, title=None, env=None, d=None):
+        # Recent versions of gnome-terminal does not support non-UTF8 charset:
+        # https://bugzilla.gnome.org/show_bug.cgi?id=732127; as a workaround,
+        # clearing the LC_ALL environment variable so it uses the locale.
+        # Once fixed on the gnome-terminal project, this should be removed.
+        if os.getenv('LC_ALL'): os.putenv('LC_ALL','')
+
         # Check version
         vernum = check_terminal_version("gnome-terminal")
         if vernum and LooseVersion(vernum) >= '3.10':



More information about the Openembedded-commits mailing list