* [PATCH 0/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none)
@ 2011-04-28 5:35 Liping Ke
2011-04-28 5:35 ` (No subject) Liping Ke
0 siblings, 1 reply; 6+ messages in thread
From: Liping Ke @ 2011-04-28 5:35 UTC (permalink / raw)
To: yocto
From: Liping Ke <liping.ke@intel.com>
Add -t options in bitbake for configuring server type.
Signed-off-by: Liping Ke <liping.ke@intel.com>
Pull URL: git://git.pokylinux.org/poky-contrib.git
Branch: lke/server_type
Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=lke/server_type
Thanks,
Liping Ke <liping.ke@intel.com>
---
Liping Ke (1):
Make bitbake server type configurable (xmlrpc, none)
bitbake/bin/bitbake | 22 +++++++++++++++++-----
1 files changed, 17 insertions(+), 5 deletions(-)
^ permalink raw reply [flat|nested] 6+ messages in thread* (No subject) 2011-04-28 5:35 [PATCH 0/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) Liping Ke @ 2011-04-28 5:35 ` Liping Ke 2011-04-28 20:31 ` [PATCH 1/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) Joshua Lock 0 siblings, 1 reply; 6+ messages in thread From: Liping Ke @ 2011-04-28 5:35 UTC (permalink / raw) To: yocto From: Liping Ke <liping.ke@intel.com> Subject: [PATCH 1/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) Add -t options in bitbake for configuring server type. Signed-off-by: Liping Ke <liping.ke@intel.com> --- bitbake/bin/bitbake | 22 +++++++++++++++++----- 1 files changed, 17 insertions(+), 5 deletions(-) diff --git a/bitbake/bin/bitbake b/bitbake/bin/bitbake index 6d05289..2c45224 100755 --- a/bitbake/bin/bitbake +++ b/bitbake/bin/bitbake @@ -39,8 +39,6 @@ import bb.msg from bb import cooker from bb import ui from bb import server -from bb.server import none -#from bb.server import xmlrpc __version__ = "1.11.0" logger = logging.getLogger("BitBake") @@ -71,7 +69,7 @@ def get_ui(config): return getattr(module, interface).main except AttributeError: sys.exit("FATAL: Invalid user interface '%s' specified.\n" - "Valid interfaces: depexp, goggle, ncurses, knotty [default]." % interface) + "Valid interfaces: depexp, goggle, ncurses, hob, knotty [default]." % interface) # Display bitbake/OE warnings via the BitBake.Warnings logger, ignoring others""" @@ -161,6 +159,9 @@ Default BBFILES are the .bb files in the current directory.""") parser.add_option("-u", "--ui", help = "userinterface to use", action = "store", dest = "ui") + parser.add_option("-t", "--servertype", help = "choose which server to user, none or xmlrpc", + action = "store", dest = "servertype") + parser.add_option("", "--revisions-changed", help = "Set the exit code depending on whether upstream floating revisions have changed or not", action = "store_true", dest = "revisions_changed", default = False) @@ -175,8 +176,19 @@ Default BBFILES are the .bb files in the current directory.""") loghandler = event.LogHandler() logger.addHandler(loghandler) - #server = bb.server.xmlrpc - server = bb.server.none + # Server type could be xmlrpc or none currently, if nothing is specified, + # default server would be none + if configuration.servertype: + server_type = configuration.servertype + else: + server_type = 'none' + + try: + module = __import__("bb.server", fromlist = [server_type]) + server = getattr(module, server_type) + except AttributeError: + sys.exit("FATAL: Invalid server type '%s' specified.\n" + "Valid interfaces: xmlrpc [default]." % servertype) # Save a logfile for cooker into the current working directory. When the # server is daemonized this logfile will be truncated. -- 1.7.0.4 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 1/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) 2011-04-28 5:35 ` (No subject) Liping Ke @ 2011-04-28 20:31 ` Joshua Lock 2011-04-29 0:23 ` Ke, Liping 0 siblings, 1 reply; 6+ messages in thread From: Joshua Lock @ 2011-04-28 20:31 UTC (permalink / raw) To: Liping Ke; +Cc: yocto Hi Liping, This looks good to me. Two minor typo nits below, once they're fixed I will create a branch on poky-contrib to collect image-creator related patches until we're ready to switch to developing against upstream bitbake. Thanks, Joshua On Thu, 2011-04-28 at 13:38 +0800, Liping Ke wrote: > From: Liping Ke <liping.ke@intel.com> > > Add -t options in bitbake for configuring server type. > > Signed-off-by: Liping Ke <liping.ke@intel.com> > --- > bitbake/bin/bitbake | 22 +++++++++++++++++----- > 1 files changed, 17 insertions(+), 5 deletions(-) > > diff --git a/bitbake/bin/bitbake b/bitbake/bin/bitbake > index 6d05289..2c45224 100755 > --- a/bitbake/bin/bitbake > +++ b/bitbake/bin/bitbake > @@ -39,8 +39,6 @@ import bb.msg > from bb import cooker > from bb import ui > from bb import server > -from bb.server import none > -#from bb.server import xmlrpc > > __version__ = "1.11.0" > logger = logging.getLogger("BitBake") > @@ -71,7 +69,7 @@ def get_ui(config): > return getattr(module, interface).main > except AttributeError: > sys.exit("FATAL: Invalid user interface '%s' specified.\n" > - "Valid interfaces: depexp, goggle, ncurses, knotty [default]." % interface) > + "Valid interfaces: depexp, goggle, ncurses, hob, knotty [default]." % interface) > > > # Display bitbake/OE warnings via the BitBake.Warnings logger, ignoring others""" > @@ -161,6 +159,9 @@ Default BBFILES are the .bb files in the current directory.""") > parser.add_option("-u", "--ui", help = "userinterface to use", > action = "store", dest = "ui") > > + parser.add_option("-t", "--servertype", help = "choose which server to user, none or xmlrpc", Can you capitalise choose please? > + action = "store", dest = "servertype") > + > parser.add_option("", "--revisions-changed", help = "Set the exit code depending on whether upstream floating revisions have changed or not", > action = "store_true", dest = "revisions_changed", default = False) > > @@ -175,8 +176,19 @@ Default BBFILES are the .bb files in the current directory.""") > loghandler = event.LogHandler() > logger.addHandler(loghandler) > > - #server = bb.server.xmlrpc > - server = bb.server.none > + # Server type could be xmlrpc or none currently, if nothing is specified, > + # default server would be none > + if configuration.servertype: > + server_type = configuration.servertype > + else: > + server_type = 'none' > + > + try: > + module = __import__("bb.server", fromlist = [server_type]) > + server = getattr(module, server_type) > + except AttributeError: > + sys.exit("FATAL: Invalid server type '%s' specified.\n" > + "Valid interfaces: xmlrpc [default]." % servertype) + "Valid interfaces: xmlrpc, none [default]." % servertype) xmlrpc isn't the default, none is :-) > > # Save a logfile for cooker into the current working directory. When the > # server is daemonized this logfile will be truncated. -- Joshua Lock Yocto Build System Monkey Intel Open Source Technology Center ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) 2011-04-28 20:31 ` [PATCH 1/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) Joshua Lock @ 2011-04-29 0:23 ` Ke, Liping 0 siblings, 0 replies; 6+ messages in thread From: Ke, Liping @ 2011-04-29 0:23 UTC (permalink / raw) To: Joshua Lock; +Cc: yocto@yoctoproject.org Hi, Josh Thanks for your very careful review indeed! I will correct them and resend the patch! Regards, criping > -----Original Message----- > From: Joshua Lock [mailto:josh@linux.intel.com] > Sent: Friday, April 29, 2011 4:32 AM > To: Ke, Liping > Cc: yocto@yoctoproject.org > Subject: Re: [yocto] [PATCH 1/1] Resend:[Image-Creator]Make bitbake server > type configurable (xmlrpc, none) > > Hi Liping, > > This looks good to me. Two minor typo nits below, once they're fixed I > will create a branch on poky-contrib to collect image-creator related > patches until we're ready to switch to developing against upstream > bitbake. > > Thanks, > Joshua ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 0/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none)
@ 2011-04-29 0:22 Liping Ke
2011-05-02 23:10 ` Joshua Lock
0 siblings, 1 reply; 6+ messages in thread
From: Liping Ke @ 2011-04-29 0:22 UTC (permalink / raw)
To: yocto
From: Liping Ke <liping.ke@intel.com>
Add -t options in bitbake for configuring server type.
Signed-off-by: Liping Ke <liping.ke@intel.com>
Pull URL: git://git.pokylinux.org/poky-contrib.git
Branch: lke/server_type
Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=lke/server_type
Thanks,
Liping Ke <liping.ke@intel.com>
---
Liping Ke (1):
Make bitbake server type configurable(xmlrpc,none)
bitbake/bin/bitbake | 22 +++++++++++++++++-----
1 files changed, 17 insertions(+), 5 deletions(-)
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH 0/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) 2011-04-29 0:22 [PATCH 0/1] " Liping Ke @ 2011-05-02 23:10 ` Joshua Lock 0 siblings, 0 replies; 6+ messages in thread From: Joshua Lock @ 2011-05-02 23:10 UTC (permalink / raw) To: Liping Ke; +Cc: yocto On Fri, 2011-04-29 at 08:22 +0800, Liping Ke wrote: > From: Liping Ke <liping.ke@intel.com> > > Add -t options in bitbake for configuring server type. Thanks Liping, this looks good to me. I've merged it into an image-creator branch on contrib I will be collecting image-creator related BitBake patches there for now with the goal of porting them to upstream BitBake and submitting to the bitbake-devel list (thought I haven't seen any traffic there for some time)... Cheers, Joshua > > Signed-off-by: Liping Ke <liping.ke@intel.com> > > Pull URL: git://git.pokylinux.org/poky-contrib.git > Branch: lke/server_type > Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=lke/server_type > > Thanks, > Liping Ke <liping.ke@intel.com> > --- > > > Liping Ke (1): > Make bitbake server type configurable(xmlrpc,none) > > bitbake/bin/bitbake | 22 +++++++++++++++++----- > 1 files changed, 17 insertions(+), 5 deletions(-) > > _______________________________________________ > yocto mailing list > yocto@yoctoproject.org > https://lists.yoctoproject.org/listinfo/yocto -- Joshua Lock Yocto Build System Monkey Intel Open Source Technology Center ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-05-02 23:14 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-04-28 5:35 [PATCH 0/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) Liping Ke 2011-04-28 5:35 ` (No subject) Liping Ke 2011-04-28 20:31 ` [PATCH 1/1] Resend:[Image-Creator]Make bitbake server type configurable (xmlrpc, none) Joshua Lock 2011-04-29 0:23 ` Ke, Liping -- strict thread matches above, loose matches on Subject: below -- 2011-04-29 0:22 [PATCH 0/1] " Liping Ke 2011-05-02 23:10 ` Joshua Lock
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.