| Submitter | Dongxiao Xu |
|---|---|
| Date | March 14, 2012, 9:26 a.m. |
| Message ID | <42a098d7aa3f119f3f6735be07da727591ef8118.1331716896.git.dongxiao.xu@intel.com> |
| Download | mbox | patch |
| Permalink | /patch/23287/ |
| State | Accepted |
| Commit | e3c5eed2244d7885418c59a62c9584f6397ee623 |
| Headers | show |
Comments
On 14/03/12 02:26, Dongxiao Xu wrote: > Currently for non-x86 architecture, there are un-resolved dependency > issue when generate universe dependency tree. Therefore disable the > handling of "NoProvider" event in Hob to enable the build for non-x86 > architectures. After we resolved the dependency for universe, we still > need to handle this event in Hob. I'm not sure we'll ever be able to strongly guarantee that NoProvider issues won't creep in. Would we better off coming up with a more tenable long term solution? > > Signed-off-by: Dongxiao Xu<dongxiao.xu@intel.com> This is a reasonable short-term solution Signed-off-by: Joshua Lock <josh@linux.intel.com> > --- > lib/bb/ui/crumbs/hobeventhandler.py | 37 ++++++++++++++++++---------------- > 1 files changed, 20 insertions(+), 17 deletions(-) > > diff --git a/lib/bb/ui/crumbs/hobeventhandler.py b/lib/bb/ui/crumbs/hobeventhandler.py > index 6c109fc..9c82bfe 100644 > --- a/lib/bb/ui/crumbs/hobeventhandler.py > +++ b/lib/bb/ui/crumbs/hobeventhandler.py > @@ -215,23 +215,26 @@ class HobHandler(gobject.GObject): > elif isinstance(event, bb.command.CommandCompleted): > self.current_phase = None > self.run_next_command() > - > - elif isinstance(event, bb.event.NoProvider): > - if event._runtime: > - r = "R" > - else: > - r = "" > - if event._dependees: > - self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r) > - else: > - self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item) > - if event._reasons: > - for reason in event._reasons: > - self.error_msg += " %s" % reason > - > - self.commands_async = [] > - self.emit("command-failed", self.error_msg) > - self.error_msg = "" > + # TODO: Currently there are NoProvider issues when generate > + # universe tree dependency for non-x86 architecture. > + # Comment the follow code to enable the build of non-x86 > + # architectures in Hob. > + #elif isinstance(event, bb.event.NoProvider): > + # if event._runtime: > + # r = "R" > + # else: > + # r = "" > + # if event._dependees: > + # self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r) > + # else: > + # self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item) > + # if event._reasons: > + # for reason in event._reasons: > + # self.error_msg += " %s" % reason > + > + # self.commands_async = [] > + # self.emit("command-failed", self.error_msg) > + # self.error_msg = "" > > elif isinstance(event, bb.command.CommandFailed): > self.commands_async = []
On Wed, 2012-03-14 at 12:37 -0700, Joshua Lock wrote: > > On 14/03/12 02:26, Dongxiao Xu wrote: > > Currently for non-x86 architecture, there are un-resolved dependency > > issue when generate universe dependency tree. Therefore disable the > > handling of "NoProvider" event in Hob to enable the build for non-x86 > > architectures. After we resolved the dependency for universe, we still > > need to handle this event in Hob. > > I'm not sure we'll ever be able to strongly guarantee that NoProvider > issues won't creep in. Would we better off coming up with a more tenable > long term solution? The current code is a strict check for NoProvider issue. Do you have any suggestion on this one? What about putting the NoProvider error in building time? Thanks, Dongxiao > > > > > Signed-off-by: Dongxiao Xu<dongxiao.xu@intel.com> > > This is a reasonable short-term solution > > Signed-off-by: Joshua Lock <josh@linux.intel.com> > > > --- > > lib/bb/ui/crumbs/hobeventhandler.py | 37 ++++++++++++++++++---------------- > > 1 files changed, 20 insertions(+), 17 deletions(-) > > > > diff --git a/lib/bb/ui/crumbs/hobeventhandler.py b/lib/bb/ui/crumbs/hobeventhandler.py > > index 6c109fc..9c82bfe 100644 > > --- a/lib/bb/ui/crumbs/hobeventhandler.py > > +++ b/lib/bb/ui/crumbs/hobeventhandler.py > > @@ -215,23 +215,26 @@ class HobHandler(gobject.GObject): > > elif isinstance(event, bb.command.CommandCompleted): > > self.current_phase = None > > self.run_next_command() > > - > > - elif isinstance(event, bb.event.NoProvider): > > - if event._runtime: > > - r = "R" > > - else: > > - r = "" > > - if event._dependees: > > - self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r) > > - else: > > - self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item) > > - if event._reasons: > > - for reason in event._reasons: > > - self.error_msg += " %s" % reason > > - > > - self.commands_async = [] > > - self.emit("command-failed", self.error_msg) > > - self.error_msg = "" > > + # TODO: Currently there are NoProvider issues when generate > > + # universe tree dependency for non-x86 architecture. > > + # Comment the follow code to enable the build of non-x86 > > + # architectures in Hob. > > + #elif isinstance(event, bb.event.NoProvider): > > + # if event._runtime: > > + # r = "R" > > + # else: > > + # r = "" > > + # if event._dependees: > > + # self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r) > > + # else: > > + # self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item) > > + # if event._reasons: > > + # for reason in event._reasons: > > + # self.error_msg += " %s" % reason > > + > > + # self.commands_async = [] > > + # self.emit("command-failed", self.error_msg) > > + # self.error_msg = "" > > > > elif isinstance(event, bb.command.CommandFailed): > > self.commands_async = [] >
On 15/03/12 01:31, Xu, Dongxiao wrote: > On Wed, 2012-03-14 at 12:37 -0700, Joshua Lock wrote: >> >> On 14/03/12 02:26, Dongxiao Xu wrote: >>> Currently for non-x86 architecture, there are un-resolved dependency >>> issue when generate universe dependency tree. Therefore disable the >>> handling of "NoProvider" event in Hob to enable the build for non-x86 >>> architectures. After we resolved the dependency for universe, we still >>> need to handle this event in Hob. >> >> I'm not sure we'll ever be able to strongly guarantee that NoProvider >> issues won't creep in. Would we better off coming up with a more tenable >> long term solution? > > The current code is a strict check for NoProvider issue. Do you have any > suggestion on this one? What about putting the NoProvider error in > building time? The ideal, from a user perspective, would I think be that any NoProvider recipes just aren't included in the list of available recipes/packages. Joshua
Patch
diff --git a/lib/bb/ui/crumbs/hobeventhandler.py b/lib/bb/ui/crumbs/hobeventhandler.py index 6c109fc..9c82bfe 100644 --- a/lib/bb/ui/crumbs/hobeventhandler.py +++ b/lib/bb/ui/crumbs/hobeventhandler.py @@ -215,23 +215,26 @@ class HobHandler(gobject.GObject): elif isinstance(event, bb.command.CommandCompleted): self.current_phase = None self.run_next_command() - - elif isinstance(event, bb.event.NoProvider): - if event._runtime: - r = "R" - else: - r = "" - if event._dependees: - self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r) - else: - self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item) - if event._reasons: - for reason in event._reasons: - self.error_msg += " %s" % reason - - self.commands_async = [] - self.emit("command-failed", self.error_msg) - self.error_msg = "" + # TODO: Currently there are NoProvider issues when generate + # universe tree dependency for non-x86 architecture. + # Comment the follow code to enable the build of non-x86 + # architectures in Hob. + #elif isinstance(event, bb.event.NoProvider): + # if event._runtime: + # r = "R" + # else: + # r = "" + # if event._dependees: + # self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r) + # else: + # self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item) + # if event._reasons: + # for reason in event._reasons: + # self.error_msg += " %s" % reason + + # self.commands_async = [] + # self.emit("command-failed", self.error_msg) + # self.error_msg = "" elif isinstance(event, bb.command.CommandFailed): self.commands_async = []
Currently for non-x86 architecture, there are un-resolved dependency issue when generate universe dependency tree. Therefore disable the handling of "NoProvider" event in Hob to enable the build for non-x86 architectures. After we resolved the dependency for universe, we still need to handle this event in Hob. Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com> --- lib/bb/ui/crumbs/hobeventhandler.py | 37 ++++++++++++++++++---------------- 1 files changed, 20 insertions(+), 17 deletions(-)