Poky Project Discussions
 help / color / mirror / Atom feed
From: Qing He <qing.he@intel.com>
To: Richard Purdie <rpurdie@linux.intel.com>
Cc: Chris Larson <clarson@kergoth.com>,
	"poky@yoctoproject.org" <poky@yoctoproject.org>
Subject: Re: [PATCH 1/1] curl: fix native dependency
Date: Tue, 30 Nov 2010 09:44:27 +0800	[thread overview]
Message-ID: <20101130014427.GA6584@qhe2-db> (raw)
In-Reply-To: <1291033557.14277.944.camel@rex>

On Mon, 2010-11-29 at 20:25 +0800, Richard Purdie wrote:
> On Sun, 2010-11-28 at 22:53 -0700, Chris Larson wrote:
> > On Sun, Nov 28, 2010 at 10:26 PM, Tian, Kevin <kevin.tian@intel.com> wrote:
> > > This also confuses me a bit. When virtclass-native is expanded, EXTRA_OECONF_append
> > > is simply a variable. In that case the expanded value should override the 1st assignment
> > > of EXTRA_OECONF_append, and then we should get:
> > >
> > > EXTRA_OECONF_append = " --without-gnutls "
> > >
> > > and then that's what we expect.
> > >
> > > I guess I may still overlook something here, and really appreciate your explanation
> > > on the whole flow which is helpful. :-)
> > 
> > No, EXTRA_OECONF_append is never a variable.  _append/_prepend are
> > operations, not part of the name.  The value gets set aside in a list
> > of appends for that variable.  One _append cannot override/replace
> > another on the same variable, its always cumulative.
> 
> Right.
> 
> Interestingly though, if I add this to curl*.bb:
> 
> FOO = "A"
> FOO_append = "B"
> FOO_append_virtclass-native = "C"
> 
> and then "bitbake curl-native -e | grep FOO" (he recipe has a
> BBCLASSEXTEND native) what should I see?
> 
> I see FOO = "AB" which is not what I thought it would do...

This is very interesting, I didn't see "AC" when preparing the patch
so went the other way. After seeing your experiment, I also tried this:

FOO = "A"
FOO_virtclass-native = "B"
FOO_virtclass-native_append = "C"

Then for curl-native, FOO = "BC", and there is an explicit variable
FOO_virtclass-native = "BC", this does not exist in RP's test.
So it's more clear to me now what "*_append is never a variable" means.


However, the gut feeling is that this construct introduces some
inconsistency. If "_append" is never a variable, but "_virtclass-native"
is, how is bitbake supposed to handle FOO_append_virtclass-native and
translate it into a FOO_virtclass-native variable?

To be more specific, if append is to be handled earlier than virtclass,
FOO may not be able to be evaluated at the time when append/prepend is
processed, as the following test case:

FOO = "A"
FOO_virtclass-native = "B"
FOO_append = "C"
FOO_append_virtclass-nativesdk = "D"

How should it be handled?

Thanks,
Qing


  parent reply	other threads:[~2010-11-30  1:49 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-17  8:32 [PATCH 0/1] curl-native build fix Qing He
2010-11-17  8:26 ` [PATCH 1/1] curl: fix native dependency Qing He
2010-11-28 14:22   ` Richard Purdie
2010-11-29  5:26     ` Tian, Kevin
2010-11-29  5:53       ` Chris Larson
2010-11-29  5:58         ` Tian, Kevin
2010-11-29 12:25         ` Richard Purdie
2010-11-29 13:04           ` Frans Meulenbroeks
2010-11-29 15:17             ` Richard Purdie
2010-12-05  9:48               ` Tian, Kevin
2010-11-29 15:24           ` Chris Larson
2010-12-05  9:32             ` Tian, Kevin
2010-12-06  1:04               ` Richard Purdie
2010-12-07  7:55                 ` Tian, Kevin
2010-12-07 12:37                   ` Richard Purdie
2010-12-08  3:12                     ` Qing He
2010-12-09 15:16                       ` Richard Purdie
2010-12-13  5:52                         ` Qing He
2010-12-13 10:48                           ` Qing He
2010-11-30  1:44           ` Qing He [this message]
2010-12-05  9:43             ` Tian, Kevin
2010-12-06  1:10               ` Richard Purdie
2010-12-07  7:56                 ` Tian, Kevin
2010-11-29  8:17     ` Qing He
2010-11-29 11:57       ` Richard Purdie
2010-11-17 18:21 ` [PATCH 0/1] curl-native build fix Saul Wold
2010-11-17 18:26   ` Scott Garman
2010-11-19 22:43     ` Saul Wold

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=20101130014427.GA6584@qhe2-db \
    --to=qing.he@intel.com \
    --cc=clarson@kergoth.com \
    --cc=poky@yoctoproject.org \
    --cc=rpurdie@linux.intel.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