summaryrefslogtreecommitdiffstats
path: root/bitbake/bin
diff options
context:
space:
mode:
authorChris Larson <chris_larson@mentor.com>2010-06-10 08:05:52 -0700
committerRichard Purdie <rpurdie@linux.intel.com>2011-01-04 14:46:33 +0000
commitd3a45c7d41a88d79389fc40eb68816e4939fb6f9 (patch)
tree443e2828e6d5e86f59b8b238607ef38646c1f23f /bitbake/bin
parent4855548ffbbb6b972f6b71d61d2b29e4758acdc7 (diff)
downloadpoky-d3a45c7d41a88d79389fc40eb68816e4939fb6f9.tar.gz
Use logging in the knotty ui, and pass the log record across directly
This kills firing of Msg* events in favor of just passing along LogRecord objects. These objects hold more than just level and message, but can also have exception information, so the UI can decide what to do with that. As an aside, when using the 'none' server, this results in the log messages in the server being displayed directly via the logging module and the UI's handler, rather than going through the server's event queue. As a result of doing it this way, we have to override the event handlers of the base logger when spawning a worker process, to ensure they log via events rather than directly. (Bitbake rev: c23c015cf8af1868faf293b19b80a5faf7e736a5) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/bin')
-rwxr-xr-xbitbake/bin/bitbake5
1 files changed, 4 insertions, 1 deletions
diff --git a/bitbake/bin/bitbake b/bitbake/bin/bitbake
index 9b2cfdf5c5..a80c01ca50 100755
--- a/bitbake/bin/bitbake
+++ b/bitbake/bin/bitbake
@@ -164,7 +164,8 @@ Default BBFILES are the .bb files in the current directory.""")
164 configuration.pkgs_to_build.extend(args[1:]) 164 configuration.pkgs_to_build.extend(args[1:])
165 configuration.initial_path = os.environ['PATH'] 165 configuration.initial_path = os.environ['PATH']
166 166
167 logger.addHandler(event.LogHandler()) 167 loghandler = event.LogHandler()
168 logger.addHandler(loghandler)
168 169
169 #server = bb.server.xmlrpc 170 #server = bb.server.xmlrpc
170 server = bb.server.none 171 server = bb.server.none
@@ -190,6 +191,8 @@ Default BBFILES are the .bb files in the current directory.""")
190 server.BitBakeServerFork(cooker, cooker.server, serverinfo, cooker_logfile) 191 server.BitBakeServerFork(cooker, cooker.server, serverinfo, cooker_logfile)
191 del cooker 192 del cooker
192 193
194 logger.removeHandler(loghandler)
195
193 # Setup a connection to the server (cooker) 196 # Setup a connection to the server (cooker)
194 serverConnection = server.BitBakeServerConnection(serverinfo) 197 serverConnection = server.BitBakeServerConnection(serverinfo)
195 198