aboutsummaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2008-04-06 20:52:59 +0000
committerRichard Purdie <rpurdie@linux.intel.com>2008-04-06 20:52:59 +0000
commit37adfd0e97484f56bc5201904f59a6b1d67545fb (patch)
treea2cd22fd7a93fae1222158bff3ee3e22a08472c5 /bin
parente91230439ca2563f43de616cc78e4011cb58ab9d (diff)
downloadbitbake-37adfd0e97484f56bc5201904f59a6b1d67545fb.tar.gz
Add experimental/toy dependency explorer UI (based on some code from Ross Burton but the bugs are mine\!)
Diffstat (limited to 'bin')
-rwxr-xr-xbin/bitbake24
1 files changed, 16 insertions, 8 deletions
diff --git a/bin/bitbake b/bin/bitbake
index f684ef51e..72e26332e 100755
--- a/bin/bitbake
+++ b/bin/bitbake
@@ -126,13 +126,16 @@ Default BBFILES are the .bb files in the current directory.""" )
# Work out which UI(s) to use
curseUI = False
+ depexplorerUI = False
if configuration.ui:
if configuration.ui == "ncurses":
curseUI = True
elif configuration.ui == "knotty" or configuration.ui == "tty" or configuration.ui == "file":
curseUI = False
+ elif configuration.ui == "depexp":
+ depexplorerUI = True
else:
- print "FATAL: Invalid user interface '%s' specified." % configuration.ui
+ print "FATAL: Invalid user interface '%s' specified.\nValid interfaces are 'ncurses', 'depexp' or the default, 'knotty'." % configuration.ui
sys.exit(1)
@@ -151,9 +154,10 @@ Default BBFILES are the .bb files in the current directory.""" )
daemonize.createDaemon(cooker.serve, cooker_logfile)
del cooker
- # Setup a frontend connection to the cooker with ui event queue
- frontend = xmlrpclib.Server("http://%s:%s" % (host, port))
- eventHandler = uievent.BBUIEventQueue(frontend)
+ # Setup a connection to the server (cooker)
+ server = xmlrpclib.Server("http://%s:%s" % (host, port), allow_none=True)
+ # Setup an event receiving queue
+ eventHandler = uievent.BBUIEventQueue(server)
# Launch the UI
try:
@@ -169,10 +173,13 @@ Default BBFILES are the .bb files in the current directory.""" )
if curseUI:
from bb.ui import ncurses
- ncurses.init(frontend, eventHandler)
+ ncurses.init(server, eventHandler)
+ elif depexplorerUI:
+ from bb.ui import depexplorer
+ depexplorer.init(server, eventHandler)
else:
from bb.ui import knotty
- return_value = knotty.init(frontend, eventHandler)
+ return_value = knotty.init(server, eventHandler)
finally:
# Don't wait for server indefinitely
@@ -183,7 +190,7 @@ Default BBFILES are the .bb files in the current directory.""" )
except:
pass
try:
- frontend.system.quit()
+ server.terminateServer()
except:
pass
return return_value
@@ -194,4 +201,5 @@ This is a Bitbake from the Unstable/Development 1.9 Branch. This software contai
You might want to use the bitbake-1.8 stable branch (if you are not a BitBake developer or tester). I'm going to sleep 5 seconds now to make sure you see that."""
import time
time.sleep(5)
- sys.exit(main())
+ ret = main()
+ sys.exit(ret)