Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Bob Cochran <openembedded@mindchasers.com>
Cc: openembedded-core@lists.openembedded.org
Subject: Re: [PATCH] allarch: Add warning about packagegroup
Date: Thu, 28 Aug 2014 00:03:15 +0100	[thread overview]
Message-ID: <1409180595.29296.122.camel@ted> (raw)
In-Reply-To: <53FE1343.4060601@mindchasers.com>

On Wed, 2014-08-27 at 13:20 -0400, Bob Cochran wrote:
> On 08/19/2014 08:35 AM, Richard Purdie wrote:
> > Since we want to start including this class conditionally, detect cases
> > where packagegroup files use the old ordering and inform the user they
> > need to update this.
> >
> > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> >
> > diff --git a/meta/classes/allarch.bbclass b/meta/classes/allarch.bbclass
> > index c953e7c..4bc9927 100644
> > --- a/meta/classes/allarch.bbclass
> > +++ b/meta/classes/allarch.bbclass
> > @@ -37,5 +37,7 @@ python () {
> >           d.setVar("EXCLUDE_FROM_SHLIBS", "1")
> >           d.setVar("INHIBIT_PACKAGE_DEBUG_SPLIT", "1")
> >           d.setVar("INHIBIT_PACKAGE_STRIP", "1")
> > +    elif bb.data.inherits_class('packagegroup', d) and not bb.data.inherits_class('nativesdk', d):
> > +        bb.error("Please ensure recipe %s sets PACKAGE_ARCH before inherit packagegroup" % d.getVar("FILE", True))
> 
> 
> I'm reviewing my recipes today to make sure everything conforms with 
> this methodology.
> 
> This is minor, but I'm curious about something with this patch regarding 
> warnings & errors:
> 
> Should I care that this commit says 'add warning' but the implementation 
> calls bb.error()?

"warning" in this sense was intended to stop the build. In order to do
that, it would have needed to be a bb.fatal though. Hindsight is
great...

> It looks like neither warning nor error throws an exception, so are they 
> interchangeable, both really warnings?
> 
> Although my build this morning produced an image, I had a couple of 
> these errors, or were they just warnings?

They aren't interchangeable. The error will have set the exit code of
bitbake which a warning wouldn't have done. Bitbake will also have
reported an error exit code. So being an error did make some difference,
just not as much as a bb.fatal would have :/

Cheers,

Richard



      reply	other threads:[~2014-08-27 23:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-19 12:35 [PATCH] allarch: Add warning about packagegroup Richard Purdie
2014-08-27 17:20 ` Bob Cochran
2014-08-27 23:03   ` Richard Purdie [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1409180595.29296.122.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=openembedded@mindchasers.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox