On 22 Dec 2023, at 04:59, Chen Qi via lists.openembedded.org <Qi.Chen=windriver....@lists.openembedded.org> wrote: >> One of the major things that comes up frequently is that the >> PACKAGECONFIG for a recipe needs to be modified to remove some >> incompatible flag from the default options. This particular option is >> not very simple though, because most recipes set PACKAGECONFIG using >> the "deferred weak" assignment, as in `PACKAGECONFIG ??= "foo bar"`. >> Because of this, any operation that attempts to modify this variable >> will overwrite the default; commonly one might like to do something >> like `PACKAGECONFIG:remove = "foo"`, but since this happens before >> weak assignment, the result is an empty string instead of just the >> value "bar". > > Checking the master branch, and I get a different result.
Indeed. With this in local.conf, or split across a recipe/bbappend: FOOBAR ??= "foo bar" FOOBAR:remove = “foo" $ bitbake-getvar FOOBAR # # $FOOBAR [2 operations] # set /yocto/ross/build/conf/local.conf:495 # [_defaultval] "foo bar" # :remove /yocto/ross/build/conf/local.conf:496 # "foo" # pre-expansion value: # "foo bar" FOOBAR=" bar” $ bitbake-getvar FOOBAR -r psplash # # $FOOBAR [2 operations] # set /home/ross/Yocto/poky/meta/recipes-core/psplash/psplash_git.bb:133 # [_defaultval] "foo bar" # :remove /home/ross/Yocto/poky/meta-poky/recipes-core/psplash/psplash_git.bbappend:3 # "foo" # pre-expansion value: # "foo bar" FOOBAR=" bar” Josh: can you provide a minimal reproducer, or did this quietly change behaviour at some point? Ross
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#1894): https://lists.openembedded.org/g/openembedded-architecture/message/1894 Mute This Topic: https://lists.openembedded.org/mt/103269425/21656 Group Owner: openembedded-architecture+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-architecture/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-