aboutsummaryrefslogtreecommitdiffstats
path: root/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:35:11 +0100
commit358016f463958640c694d031a481264a0e770802 (patch)
treeb10f7e84ad6af5ae62374355de2bda4df52478ee /bitbake
parent8b8be74ed21b878b2fe30d5b76ff0648e6e48c18 (diff)
downloadopenembedded-core-contrib-358016f463958640c694d031a481264a0e770802.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. (Bitbake rev: e3c213015953d1a0afb5ef4be59e1264990e5cee) Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rwxr-xr-xbitbake/bin/bitbake9
-rw-r--r--bitbake/doc/bitbake.16
2 files changed, 11 insertions, 4 deletions
diff --git a/bitbake/bin/bitbake b/bitbake/bin/bitbake
index 420e69d0c9..478ac06124 100755
--- a/bitbake/bin/bitbake
+++ b/bitbake/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
diff --git a/bitbake/doc/bitbake.1 b/bitbake/doc/bitbake.1
index aa096203e4..d9d39020f5 100644
--- a/bitbake/doc/bitbake.1
+++ b/bitbake/doc/bitbake.1
@@ -103,7 +103,13 @@ Show debug logging for the specified logging domains
.TP
.B \-P, \-\-profile
profile the command and print a report
+
+.SH ENVIRONMENT VARIABLES
+bitbake uses the following environment variables to control its
+operation:
.TP
+.B BITBAKE_UI
+The bitbake user interface; overridden by the \fB-u\fP commandline option.
.SH AUTHORS
BitBake was written by