summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/ui/uihelper.py
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb/ui/uihelper.py')
-rw-r--r--bitbake/lib/bb/ui/uihelper.py41
1 files changed, 0 insertions, 41 deletions
diff --git a/bitbake/lib/bb/ui/uihelper.py b/bitbake/lib/bb/ui/uihelper.py
index a703387fb8..db70b763f3 100644
--- a/bitbake/lib/bb/ui/uihelper.py
+++ b/bitbake/lib/bb/ui/uihelper.py
@@ -57,44 +57,3 @@ class BBUIHelper:
57 self.needUpdate = False 57 self.needUpdate = False
58 return (self.running_tasks, self.failed_tasks) 58 return (self.running_tasks, self.failed_tasks)
59 59
60 def findServerDetails(self):
61 import sys
62 import optparse
63 from bb.server.xmlrpc import BitbakeServerInfo, BitBakeServerConnection
64 host = ""
65 port = 0
66 bind = ""
67 parser = optparse.OptionParser(
68 usage = """%prog -H host -P port -B bindaddr""")
69
70 parser.add_option("-H", "--host", help = "Bitbake server's IP address",
71 action = "store", dest = "host", default = None)
72
73 parser.add_option("-P", "--port", help = "Bitbake server's Port number",
74 action = "store", dest = "port", default = None)
75
76 parser.add_option("-B", "--bind", help = "Hob2 local bind address",
77 action = "store", dest = "bind", default = None)
78
79 options, args = parser.parse_args(sys.argv)
80 for key, val in options.__dict__.items():
81 if key == 'host' and val:
82 host = val
83 elif key == 'port' and val:
84 port = int(val)
85 elif key == 'bind' and val:
86 bind = val
87
88 if not host or not port or not bind:
89 parser.print_usage()
90 sys.exit(1)
91
92 serverinfo = BitbakeServerInfo(host, port)
93 clientinfo = (bind, 0)
94 connection = BitBakeServerConnection(serverinfo, clientinfo)
95
96 server = connection.connection
97 eventHandler = connection.events
98
99 return server, eventHandler, host, bind
100