]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
init-manager: define dev_manager for all init managers
authorPeter Marko <peter.marko@siemens.com>
Wed, 27 Nov 2024 19:23:33 +0000 (20:23 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 28 Nov 2024 12:26:57 +0000 (12:26 +0000)
Currently VIRTUAL-RUNTIME_dev_manager is defined by some init managers
with "??=" and in packagegroup-core-boot with "?=".
This means that this variable is different in this package group and in
all other the recipes.
This was discovered when trying to use new feature INIT_MANAGER when
migrating to scarthgap and using systemd distro. After deleting all
VIRTUAL_RUNTIME providers defined in init-manager-systemd udev was
installed additionally via packagegroup-core-boot.

Having a distro settings overriden in single recipe is wrong and needs
to be corrected. Therefore let's define the setting in all init managers
and remove it from packagegroup-core-boot.

core-image-tiny-initramfs has a dilemma - use busybox-mdev even if
distro does not enable it in busybox recipe to keep the image tiny, or
rather not install it even if distro enables it in busybox.
This patch chooses the first option.

Signed-off-by: Peter Marko <peter.marko@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/conf/distro/include/init-manager-none.inc
meta/conf/distro/include/init-manager-sysvinit.inc
meta/recipes-core/images/core-image-tiny-initramfs.bb
meta/recipes-core/packagegroups/packagegroup-core-boot.bb

index bbedf898f76bb8a6dae0e6aa6ae580409e477450..6ece5c9906173a382fc0e190fa7de6cca4171cc3 100644 (file)
@@ -1,3 +1,4 @@
 VIRTUAL-RUNTIME_init_manager ??= "sysvinit"
 VIRTUAL-RUNTIME_initscripts ??= "initscripts"
 VIRTUAL-RUNTIME_login_manager ??= "busybox"
+VIRTUAL-RUNTIME_dev_manager ??= "udev"
index aa2393944d62bffd25322f057223e9f21d9d104e..e2d17b358d4ea00adbe665bf66b7310641798462 100644 (file)
@@ -4,3 +4,4 @@ DISTRO_FEATURES_BACKFILL_CONSIDERED:append = " systemd"
 VIRTUAL-RUNTIME_init_manager ??= "sysvinit"
 VIRTUAL-RUNTIME_initscripts ??= "initscripts"
 VIRTUAL-RUNTIME_login_manager ??= "busybox"
+VIRTUAL-RUNTIME_dev_manager ??= "udev"
index 7a71d55b1e8830b6078e4d3d8ef9e13474ea91f5..c2aa68c7882c93747ba80f28296cecb7e6053bd8 100644 (file)
@@ -6,6 +6,9 @@ first 'init' program more efficiently. core-image-tiny-initramfs doesn't \
 actually generate an image but rather generates boot and rootfs artifacts \
 that can subsequently be picked up by external image generation tools such as wic."
 
+# if distro does not override VIRTUAL-RUNTIME_dev_manager and default in different, busybox is compiled without mdev support
+# however this keeps the image small by not installing heavy-weight manager and in initramfs it may not even be necessary
+# override in distro if needed
 VIRTUAL-RUNTIME_dev_manager ?= "busybox-mdev"
 
 PACKAGE_INSTALL = "initramfs-live-boot-tiny packagegroup-core-boot dropbear ${VIRTUAL-RUNTIME_base-utils} ${VIRTUAL-RUNTIME_dev_manager} base-passwd ${ROOTFS_BOOTSTRAP_INSTALL}"
index fecc3334ea002b05ce5848988988a0d04d317815..fa06092e279c0ce146e9551ca54dbd646c6290d9 100644 (file)
@@ -10,7 +10,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
 inherit packagegroup
 
 # Distro can override the following VIRTUAL-RUNTIME providers:
-VIRTUAL-RUNTIME_dev_manager ?= "udev"
 VIRTUAL-RUNTIME_keymaps ?= "keymaps"
 
 EFI_PROVIDER ??= "grub-efi"