Hi Martin,

its Yocto chant #1: "Recipe data is local, configuration data is global."

Means: whatever happens in a recipe, other recipes can't see it. Whatever
happens in a configuration file (local, machine, distro), it is visible
everywhere. An image is just a recipe, in the end - so whatever you do
there, it cannot affect the distribution. In a nutshell: you can't set
DISTRO_FEATURES in an image.

Greetz

On Thu, Nov 3, 2022 at 8:54 PM Martin Leduc via lists.yoctoproject.org
<[email protected]> wrote:

> Hi everyone,
>
> I'm wondering how to figure out the scope of a set of parameters.
> Example.  I have an Image (my-core-image-minimal.bb) recipe containing
> the following parameters
>
> ###########
> # systemd #
> ###########
> inherit systemd
> DISTRO_FEATURES_append = " systemd "
> DISTRO_FEATURES_BACKFILL_CONSIDERED += " sysvinit "
> VIRTUAL-RUNTIME_init_manager = "systemd"
> VIRTUAL-RUNTIME_initscripts = "systemd-compat-units"
> IMAGE_ROOTFS_EXTRA_SPACE_append = "${@bb.utils.contains("DISTRO_FEATURES",
> "systemd", " + 4096", "" ,d)}"
>
> SystemD isn't deployed in my image as the init_manager.  Now, I put the
> parameters into local.conf
>
> ###########
> # systemd #
> ###########
> INHERIT += " systemd "
> DISTRO_FEATURES_append = " systemd "
> DISTRO_FEATURES_BACKFILL_CONSIDERED += " sysvinit "
> VIRTUAL-RUNTIME_init_manager = "systemd"
> VIRTUAL-RUNTIME_initscripts = "systemd-compat-units"
> IMAGE_ROOTFS_EXTRA_SPACE_append = "${@bb.utils.contains("DISTRO_FEATURES",
> "systemd", " + 4096", "" ,d)}"
>
> It works!!!!
>
> I'm confused because my comprehension is when I run bitbake
> my-core-image-minimal , the parameters defined in this image are defined at
> the top level of the bitbake configuration parameters no?
>
> Seriously, I have a lots of difficulties understanding the scope of a
> parameter, where to put it.  At the limit, my comprehension is that I can
> have two recipes:
>
>    - my-core-image-minimal-sysvinit.bb
>    - my-core-image-minimal-systemd.bb
>
> The systemd one define the systemd parameters, the sysvinit doesn't
> implement anything else.
>
> What does I miss?
>
> Thank you all :)
> Martin
>
>
>
>
> 
>
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#58478): https://lists.yoctoproject.org/g/yocto/message/58478
Mute This Topic: https://lists.yoctoproject.org/mt/94791874/21656
Mute #systemd:https://lists.yoctoproject.org/g/yocto/mutehashtag/systemd
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to