[OE-core] setting EXTRA_IMAGE_FEATURES explicitly in .bb file can screw things up

Andrei Gherzan andrei at gherzan.ro
Mon Jul 9 08:59:38 UTC 2012


On Sat, Jul 7, 2012 at 9:52 PM, Robert P. J. Day <rpjday at crashcourse.ca>wrote:

>
>   a while back, i whined about the inconsistent usage of
> EXTRA_IMAGE_FEATURES, like this as a snippet:
>
> meta/recipes-sato/images/core-image-sato-sdk.bb:EXTRA_IMAGE_FEATURES +=
> "tools-debug tools-profile tools-testapps debug-tweaks"
> meta/recipes-rt/images/core-image-rt-sdk.bb:EXTRA_IMAGE_FEATURES +=
> "tools-debug tools-profile tools-testapps debug-tweaks"
> meta/recipes-extended/images/core-image-lsb-sdk.bb:EXTRA_IMAGE_FEATURES =
> "tools-debug tools-profile tools-testapps debug-tweaks"
>
> notice the mixing of "+=" and "=", which seems messy.  then i ran
> across this in core-image-lsb-sdk.bb:
>
> IMAGE_FEATURES += "apps-console-core tools-sdk dev-pkgs ssh-server-openssh"
> EXTRA_IMAGE_FEATURES = "tools-debug tools-profile tools-testapps
> debug-tweaks"
>
>   that *can't* be right, can it?  the explicit setting of
> EXTRA_IMAGE_FEATURES in that recipe file will override any such
> setting in one's local.conf file, won't it?  and that's how the
> current manual *advises* how to add more features through your
> local.conf.
>
>   i tested this target with a standard local.conf, and checked the
> environment to see:
>
> ... snip ...
> IMAGE_FEATURES="apps-console-core debug-tweaks tools-sdk
> tools-testapps dev-pkgs tools-profile tools-debug ssh-server-openssh"
>
> which looks fine according to the .bb file.
>
>   but if i add the following to my local.conf file (as the manual
> suggests i do to add another feature):
>
> EXTRA_IMAGE_FEATURES = "nfs-server"
>
> i see *no* difference in the environment.  hasn't the setting in the
> .bb file overridden the one in my local.conf?
>
>   i *can* get nfs-server added to my list of features with
> (predictably):
>
> IMAGE_FEATURES += "nfs-server"
>
> but that doesn't strike me as a proper solution and will certainly
> come as an unpleasant surprise to someone eventually.  thoughts?
>
>
I agree that there is a problem with this image. Anyway the best way to
debug a scenario like this is to use bitbake -e and grep on the thing you
are interested in. I tried to add a feature to local conf and, as i
expected, EXTRA_IMAGE_FEATURES ended up overwritten by recipe.

So IMHO the EXTRA_IMAGE_FEATURES variable in the image should be merged in
the IMAGE_FEATURES above. I don't see the meaning of it.

@g
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20120709/25e5066c/attachment-0002.html>


More information about the Openembedded-core mailing list