From e386fe4542865119ae7e1574e260c037e926239e Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Tue, 7 Jun 2011 23:46:50 +0100 Subject: bitbake: Sync up with upstream cosmetic changes for bin/bitbake Sync cosmetic differences between bitbake in poky and bitbake upstream in preparation for resolving the real code differences in the server handling. Signed-off-by: Richard Purdie --- bitbake/bin/bitbake | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) (limited to 'bitbake/bin') diff --git a/bitbake/bin/bitbake b/bitbake/bin/bitbake index 6d0528953c..acd086753f 100755 --- a/bitbake/bin/bitbake +++ b/bitbake/bin/bitbake @@ -42,10 +42,11 @@ from bb import server from bb.server import none #from bb.server import xmlrpc -__version__ = "1.11.0" +__version__ = "1.13.0" logger = logging.getLogger("BitBake") + class BBConfiguration(object): """ Manages build options and configurations for one run @@ -172,9 +173,6 @@ Default BBFILES are the .bb files in the current directory.""") ui_main = get_ui(configuration) - loghandler = event.LogHandler() - logger.addHandler(loghandler) - #server = bb.server.xmlrpc server = bb.server.none @@ -185,6 +183,10 @@ Default BBFILES are the .bb files in the current directory.""") bb.utils.init_logger(bb.msg, configuration.verbose, configuration.debug, configuration.debug_domains) + # Ensure logging messages get sent to the UI as events + handler = bb.event.LogHandler() + logger.addHandler(handler) + # Clear away any spurious environment variables. But don't wipe the # environment totally. This is necessary to ensure the correct operation # of the UIs (e.g. for DISPLAY, etc.) @@ -198,17 +200,11 @@ Default BBFILES are the .bb files in the current directory.""") server.BitBakeServerFork(cooker, cooker.server, serverinfo, cooker_logfile) del cooker - logger.removeHandler(loghandler) + logger.removeHandler(handler) # Setup a connection to the server (cooker) server_connection = server.BitBakeServerConnection(serverinfo) - # Launch the UI - if configuration.ui: - ui = configuration.ui - else: - ui = "knotty" - try: return server.BitbakeUILauch().launch(serverinfo, ui_main, server_connection.connection, server_connection.events) finally: @@ -222,3 +218,4 @@ if __name__ == "__main__": import traceback traceback.print_exc(5) sys.exit(ret) + -- cgit v1.2.3-54-g00ecf