[OE-core] DISTRO_FEATURES_BACKFILL_CONSIDERED_append usage

Paul Eggleton paul.eggleton at linux.intel.com
Tue Apr 23 17:30:02 UTC 2013


On Tuesday 23 April 2013 10:07:35 Koen Kooi wrote:
> I've had the following in my DISTRO.conf for a while now:
> 
> 	DISTRO_FEATURES_BACKFILL_CONSIDERED_append = " sysvinit"
> 
> And that seems to do the right thing:
> 
> 	[koen at rrMBP v2013.06]$ MACHINE=minnow bitbake systemd -e | grep
> DISTRO_FEATURES | grep BACK # $DISTRO_FEATURES_BACKFILL
> 	DISTRO_FEATURES_BACKFILL="pulseaudio sysvinit"
> 	# $DISTRO_FEATURES_BACKFILL_CONSIDERED [2 operations]
> 	DISTRO_FEATURES_BACKFILL_CONSIDERED="sysvinit"
> 
> Except that it doesn't:
> 
> [koen at rrMBP v2013.06]$ MACHINE=minnow bitbake systemd -e | grep
> DISTRO_FEATURES | grep sysvinit #   "alsa argp bluetooth ext2 ipv4 ipv6
> irda largefile nfs pam pci pcmcia ppp smbfs systemd usbgadget usbhost vfat
> wifi xattr zeroconf tk x11 wayland 3g 	pulseaudio ${DISTRO_GLFEATURES}
> ${DISTRO_FEATURES_LIBC} ${LDISGOLD} sysvinit" DISTRO_FEATURES="alsa argp
> bluetooth ext2 ipv4 ipv6 irda largefile nfs pam pci pcmcia ppp smbfs
> systemd usbgadget usbhost vfat wifi xattr zeroconf tk x11 wayland 3g
> pulseaudio opengl ipv4 ipv6 libc-backtrace libc-big-macros libc-bsd
> libc-cxx-tests libc-catgets libc-charsets libc-crypt                       
>                  libc-crypt-ufc libc-db-aliases libc-envz libc-fcvt
> libc-fmtmsg libc-fstab libc-ftraverse                                      
>  libc-getlogin libc-idn libc-inet-anl libc-libm libc-libm-big libc-locales
> libc-locale-code                                    libc-memusage libc-nis
> libc-nsswitch libc-rcmd libc-rtld-debug libc-spawn libc-streams libc-sunrpc
>                                   libc-utmp libc-utmpx libc-wordexp
> libc-posix-clang-wchar libc-posix-regexp libc-posix-regexp-glibc           
>                            libc-posix-wchar-io  sysvinit"
> 
> Remembering the IMAGE_FSTYPES_append vs. += discussion, I tried:
> 
> 	DISTRO_FEATURES_BACKFILL_CONSIDERED += "sysvinit"
> 
> The result:
> 
> 	[koen at rrMBP v2013.06]$ MACHINE=minnow bitbake systemd -e | grep
> DISTRO_FEATURES | grep sysvinit ERROR: Please ensure that your setting of
> VIRTUAL-RUNTIME_init_manager (sysvinit) matches the entries enabled in
> DISTRO_FEATURES
> 
> Hmmm, let's set VIRTUAL-RUNTIME_init_manager and retry:
> 
> 	[koen at rrMBP v2013.06]$ MACHINE=minnow bitbake systemd -e | grep
> DISTRO_FEATURES | grep sysvinit DISTRO_FEATURES_BACKFILL="pulseaudio
> sysvinit"
> 	DISTRO_FEATURES_BACKFILL_CONSIDERED="sysvinit"
> 
> \o/
> 
> So, is this a bug or intended behaviour for
> DISTRO_FEATURES_BACKFILL_CONSIDERED_append?

The trouble is there has to be some order in processing these variables, and 
the backfilling has to happen early or you can't base later processing on the 
value of DISTRO_FEATURES and have it work properly. (FYI, the backfilling was 
moved slightly earlier in 22429cdf79ed952072707a929643c7386fa7e056, i.e. 
fairly recently.) The _append operation by its nature happens late, which is 
probably why you see the effect above.

You should just be setting DISTRO_FEATURES_BACKFILL_CONSIDERED with = rather 
than appending. This variable is intended since its introduction to be set by 
the distro config and shouldn't really be set elsewhere. If you must compose 
values across multiple configuration files, use += for this variable.

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre




More information about the Openembedded-core mailing list