Skip to contentSkip to conversation

is it "IMAGE_INSTALL +=" or "IMAGE_INSTALL_append ="?

DISCUSSION Robert P. J. Day 4 participants 4 messages Jun 19, 2012 – Jun 20, 2012

lore
Share & tools
lore
#0 lore raw

currently, the dev manual (Section 4.2.1) proposes the use of

IMAGE_INSTALL += "strace"

but the poky ref manual in the variable glossary explicitly discourages that form, and instead recommends

IMAGE_INSTALL_append = " package-name"

can we agree that the "_append" form is preferred? thoughts?

rday

Signature · 7 lines
========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================
#1 lore raw
Quoted 10 lines · On Tuesday 19 June 2012 08:22:00 Robert P. J. Day wrote:

currently, the dev manual (Section 4.2.1) proposes the use of

IMAGE_INSTALL += "strace"

but the poky ref manual in the variable glossary explicitly discourages that form, and instead recommends

IMAGE_INSTALL_append = " package-name"

can we agree that the "_append" form is preferred? thoughts?

The reference manual is a little unclear on what "ordering issues" means. += works just fine, it's just that if you happen to use it at some point before core-image.bbclass line sets it with ?= (i.e. either in local.conf or before the "inherit core-image" line in your image recipe) the ?= line in core- image.bbclass will do nothing and you'll end up with much less in the IMAGE_INSTALL list than you expected. If you use _append, you can have that anywhere you like and it will always work, with the caveat that if you forget to add a leading space in the value to be appended, things will break.

Note that the part of 4.2.1 in the dev manual you refer to is specifically talking about making a copy of an image recipe and putting the IMAGE_INSTALL += at the end, which will always work and won't suffer from any leading space issues. I'm not sure what we should change to improve this...

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre
#2 lore raw
Quoted 21 lines · Paul Eggleton
Quoted 10 lines · On Tuesday 19 June 2012 08:22:00 Robert P. J. Day wrote:

currently, the dev manual (Section 4.2.1) proposes the use of

IMAGE_INSTALL += "strace"

but the poky ref manual in the variable glossary explicitly discourages that form, and instead recommends

IMAGE_INSTALL_append = " package-name"

can we agree that the "_append" form is preferred? thoughts?

The reference manual is a little unclear on what "ordering issues" means. += works just fine, it's just that if you happen to use it at some point before core-image.bbclass line sets it with ?= (i.e. either in local.conf or before the "inherit core-image" line in your image recipe) the ?= line in core- image.bbclass will do nothing and you'll end up with much less in the IMAGE_INSTALL list than you expected. If you use _append, you can have that anywhere you like and it will always work, with the caveat that if you forget to add a leading space in the value to be appended, things will break.

Quoted 4 lines

Note that the part of 4.2.1 in the dev manual you refer to is specifically talking about making a copy of an image recipe and putting the IMAGE_INSTALL += at the end, which will always work and won't suffer from any leading space issues. I'm not sure what we should change to improve this...

Is there a section that explains the order in which all these things happen? i.e. items in local.conf happen before/after...

Chris Tapp

[email protected]
www.keylevel.com

#3 lore raw

Hi,

Quoted 2 lines · Chris Tapp

Is there a section that explains the order in which all these things happen? i.e. items in local.conf happen before/after...

IIRC, the evaluation orders is:

1. variables on the command line (e.g., 'MACHINE=beagleboard bitbake myimage') are evaluated first,

2. variables in local.conf,

3. Rest depends on the order of things in bblayers.conf *and* how any given layer.conf is implemented (some layers preppend their stuff to the BBPATH and some layers append; from memory the Yocto layers prepend, but layers from OE usually append, and this inconsistency makes for lot of fun when combining layers into custom distro).

Tomas