summaryrefslogtreecommitdiffstats
path: root/bitbake
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake')
-rw-r--r--bitbake/lib/bb/ui/toasterui.py19
1 files changed, 17 insertions, 2 deletions
diff --git a/bitbake/lib/bb/ui/toasterui.py b/bitbake/lib/bb/ui/toasterui.py
index fec69621f1..2d443776ba 100644
--- a/bitbake/lib/bb/ui/toasterui.py
+++ b/bitbake/lib/bb/ui/toasterui.py
@@ -168,8 +168,23 @@ def main(server, eventHandler, params):
168 build_history_enabled = False 168 build_history_enabled = False
169 169
170 if not params.observe_only: 170 if not params.observe_only:
171 logger.error("ToasterUI can only work in observer mode") 171 params.updateFromServer(server)
172 return 1 172 params.updateToServer(server, os.environ.copy())
173 cmdline = params.parseActions()
174 if not cmdline:
175 print("Nothing to do. Use 'bitbake world' to build everything, or run 'bitbake --help' for usage information.")
176 return 1
177 if 'msg' in cmdline and cmdline['msg']:
178 logger.error(cmdline['msg'])
179 return 1
180
181 ret, error = server.runCommand(cmdline['action'])
182 if error:
183 logger.error("Command '%s' failed: %s" % (cmdline, error))
184 return 1
185 elif ret != True:
186 logger.error("Command '%s' failed: returned %s" % (cmdline, ret))
187 return 1
173 188
174 # set to 1 when toasterui needs to shut down 189 # set to 1 when toasterui needs to shut down
175 main.shutdown = 0 190 main.shutdown = 0