All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: "Xu, Dongxiao" <dongxiao.xu@intel.com>
Cc: yocto@yoctoproject.org
Subject: Re: One question about taskdata and runqueue
Date: Mon, 27 Feb 2012 16:19:27 +0000	[thread overview]
Message-ID: <1330359567.4593.29.camel@ted> (raw)
In-Reply-To: <1330350708.4803.15.camel@dongxiao-osel>

On Mon, 2012-02-27 at 21:51 +0800, Xu, Dongxiao wrote:
> Hi list,
> 
> If I have two recipes, see following. Both of them provides
> "virtual/test" and has package named "test-test", the only difference is
> the RDEPENDS of the package "test-test".
> 
> test-a_1.0.bb
> 
> PROVIDES = "virtual/test"
> PACKAGES = "test-test"
> # Assume that the abcd package are provided by recipe abcd.bb
> RDEPENDS_test-test = "abcd"
> 
> 
> test-b_1.0.bb
> 
> PROVIDES = "virtual/test"
> PACKAGES = "test-test"
> 
> In a certain configuration file, we have the PREFERRED_PROVIDER set as:
> PREFERRED_PROVIDER_virtual/test = "test-a".
> 
> Then if a real recipe, for example, the 'v86d', depends on the
> "virtual/test":
> DEPENDS = "virtual/test"
> 
> Finally if I run the following command:
> # bitbake v86d
> 
> We know that the recipe "abcd" will be included in the runqueue.
> 
> My question is, can we get the build dependency to recipe "abcd" through
> taskdata? Or it is finalized until we create the RunQueue object?

task data should have a list of providers for "virtual/test", sorted in
priority order. There should be two entries in that list, one for test-a
and test-b. Since you set the preferred provider, you should have test-a
as the first item.

Once you resolve it to a recipe file, you should be able to look at the
recipe file's dependencies in dataCache.

The trouble is you're now resolving all the dependencies in the code I
think you're referring to. This was in general the job of
prepare_runqueue() and I'm starting to worry you're duplicating its
functionality.

Cheers,

Richard



  reply	other threads:[~2012-02-27 16:19 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-27 13:51 One question about taskdata and runqueue Xu, Dongxiao
2012-02-27 16:19 ` Richard Purdie [this message]
2012-02-28  2:21   ` Xu, Dongxiao

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=1330359567.4593.29.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=dongxiao.xu@intel.com \
    --cc=yocto@yoctoproject.org \
    /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 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.