From: Paul Eggleton <paul.eggleton@linux.intel.com>
To: Brad Litterell <bradl@taser.com>
Cc: yocto@yoctoproject.org
Subject: Re: What are _virtual providers? and other Suffixes?
Date: Wed, 21 Aug 2013 00:33:22 +0100 [thread overview]
Message-ID: <7610515.7dZZ0L6LcG@helios> (raw)
In-Reply-To: <78289786-2223-441A-B086-7E71B1314168@taser.com>
On Tuesday 20 August 2013 23:16:56 Brad Litterell wrote:
> Thanks for taking the time to explain, very enlightening. I think I
> understood it, please allow me to play back my understanding:
>
> 1. _virtual is part of the variable name, and is not a special type of
> override.
Actually, virtual/kernel is an override as well. The way a few variables,
including PREFERRED_PROVIDER, are used is that OVERRIDES is set to include the
item being dealt with when the variable is read, thus specifically with
PREFERRED_PROVIDER you always override it with the name of the target you wish
to select the provider for.
> 2. PREFERRED_PROVIDER_virtual/kernel_am335x-evm breaks into:
> "PREFERRED_PROVIDER_virtual/kernel" with an override condition of
> "am335x-evm"
Outside of the part of the code where it's actually read, yes. Within that
code the override "virtual/kernel" will be applied when it's looking to see
what the provider for "virtual/kernel" should be, and thus it will get the
appropriate value for the PREFERRED_PROVIDER variable. So technically the
variable is just PREFERRED_PROVIDER.
> 3. So for the jpeg case:
> >> PREFERRED_PROVIDER_jpeg = "libjpeg-turbo"
> >>
> >> PREFERRED_PROVIDER_jpeg_armv5te = "jpeg"
>
> Could this have also been _virtual/jpeg? It's just that some components use
> the _virtual convention and others don't?
The prefix is virtual/ not _virtual, and as I mentioned earlier virtual/ is
just a convention (although there are a few isolated parts of the code that
specifically look for the virtual/ prefix). The mechanism will work in the same
way here; recipes that need jpeg decoding have "jpeg" in DEPENDS and providing
libjpeg-turbo has jpeg in its PROVIDES, which it does, we can select between
two different recipes providing that - jpeg and libjpeg-turbo (where the latter
is provided at all of course, i.e. when you have the meta-oe layer in your
configuration).
I don't think there's any special reason we don't have virtual/jpeg rather
than jpeg here other than that having multiple jpeg decoding libraries is a
relatively new situation compared to others such as virtual/kernel, and there
are already a bunch of recipes out there referring to "jpeg" in their DEPENDS.
(One wonders why there is a need for multiple jpeg decoding libraries in the
first place, but that's a different can of worms...)
Cheers,
Paul
--
Paul Eggleton
Intel Open Source Technology Centre
next prev parent reply other threads:[~2013-08-20 23:33 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-19 22:51 What are _virtual providers? and other Suffixes? Brad Litterell
2013-08-20 22:27 ` Paul Eggleton
2013-08-20 23:16 ` Brad Litterell
2013-08-20 23:33 ` Paul Eggleton [this message]
2013-08-20 23:42 ` Brad Litterell
2013-08-21 14:26 ` Paul Eggleton
2013-08-21 16:27 ` Brad Litterell
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=7610515.7dZZ0L6LcG@helios \
--to=paul.eggleton@linux.intel.com \
--cc=bradl@taser.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.