summaryrefslogtreecommitdiffstats
path: root/bin/bitbake
diff options
context:
space:
mode:
authorEnrico Scholz <enrico.scholz@sigma-chemnitz.de>2012-05-20 17:19:11 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-05-23 11:26:30 +0100
commite3c213015953d1a0afb5ef4be59e1264990e5cee (patch)
treed43b0fab4793de3fac31dd0d2f9d38686d933095 /bin/bitbake
parentc993b7c457f8b7776e8a5dff253bfa0724bc2cae (diff)
downloadbitbake-contrib-e3c213015953d1a0afb5ef4be59e1264990e5cee.tar.gz
bitbake: support $BITBAKE_UI environment
Patch adds support for a $BITBAKE_UI environment variable which allows to configure the preferred user interface. Although an '-u' option (which will override the environment variable) exists already, it was required to specify this option on every invocation of bitbake. Because user interface is instanciated very early in the program it is not possible to use bitbake.conf for setting up a default. An environment variable (which acts in a similar category like $PAGER or $EDITOR) is a simple way for configuring the default. Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bin/bitbake')
-rwxr-xr-xbin/bitbake9
1 files changed, 5 insertions, 4 deletions
diff --git a/bin/bitbake b/bin/bitbake
index 420e69d0c..478ac0612 100755
--- a/bin/bitbake
+++ b/bin/bitbake
@@ -56,10 +56,11 @@ class BBConfiguration(object):
def get_ui(config):
- if config.ui:
- interface = config.ui
- else:
- interface = 'knotty'
+ if not config.ui:
+ # modify 'ui' attribute because it is also read by cooker
+ config.ui = os.environ.get('BITBAKE_UI', 'knotty')
+
+ interface = config.ui
try:
# Dynamically load the UI based on the ui name. Although we