diff mbox series

[v3,2/2] systemd: add usrmerge to REQUIRED_DISTRO_FEATURES

Message ID 20220713165533.125600-2-luca.boccassi@gmail.com
State New
Headers show
Series [v3,1/2] poky-altcfg: enable usrmerge | expand

Commit Message

Luca Boccassi July 13, 2022, 4:55 p.m. UTC
From: Luca Boccassi <luca.boccassi@microsoft.com>

Support for unmerged-usr is deprecated upstream, taints the system and will be
removed in the near future.
Enforce building merged-usr images when using systemd.

Signed-off-by: Luca Boccassi <luca.boccassi@microsoft.com>
---
v3: use += without :append

 meta/recipes-core/systemd/systemd-compat-units.bb | 2 +-
 meta/recipes-core/systemd/systemd-serialgetty.bb  | 2 +-
 meta/recipes-core/systemd/systemd.inc             | 5 +++++
 meta/recipes-core/systemd/systemd_251.2.bb        | 2 +-
 4 files changed, 8 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/meta/recipes-core/systemd/systemd-compat-units.bb b/meta/recipes-core/systemd/systemd-compat-units.bb
index 55ebf99117..8831578010 100644
--- a/meta/recipes-core/systemd/systemd-compat-units.bb
+++ b/meta/recipes-core/systemd/systemd-compat-units.bb
@@ -14,7 +14,7 @@  INHIBIT_DEFAULT_DEPS = "1"
 
 ALLOW_EMPTY:${PN} = "1"
 
-REQUIRED_DISTRO_FEATURES = "systemd"
+REQUIRED_DISTRO_FEATURES += "systemd"
 
 SYSTEMD_DISABLED_SYSV_SERVICES = " \
   busybox-udhcpc \
diff --git a/meta/recipes-core/systemd/systemd-serialgetty.bb b/meta/recipes-core/systemd/systemd-serialgetty.bb
index fd888bb834..0987c3f416 100644
--- a/meta/recipes-core/systemd/systemd-serialgetty.bb
+++ b/meta/recipes-core/systemd/systemd-serialgetty.bb
@@ -14,7 +14,7 @@  S = "${WORKDIR}"
 
 # As this package is tied to systemd, only build it when we're also building systemd.
 inherit features_check
-REQUIRED_DISTRO_FEATURES = "systemd"
+REQUIRED_DISTRO_FEATURES += "systemd"
 
 do_install() {
 	if [ ! -z "${SERIAL_CONSOLES}" ] ; then
diff --git a/meta/recipes-core/systemd/systemd.inc b/meta/recipes-core/systemd/systemd.inc
index b8dbe2263a..f9e109bba4 100644
--- a/meta/recipes-core/systemd/systemd.inc
+++ b/meta/recipes-core/systemd/systemd.inc
@@ -21,3 +21,8 @@  SRC_URI = "git://github.com/systemd/systemd-stable.git;protocol=https;branch=${S
 "
 
 S = "${WORKDIR}/git"
+
+# unmerged-usr support is deprecated upstream, taints the system and will be
+# removed in the near future. Fail the build if it is not enabled.
+inherit features_check
+REQUIRED_DISTRO_FEATURES = "usrmerge"
diff --git a/meta/recipes-core/systemd/systemd_251.2.bb b/meta/recipes-core/systemd/systemd_251.2.bb
index bb3c59f418..ade2e61676 100644
--- a/meta/recipes-core/systemd/systemd_251.2.bb
+++ b/meta/recipes-core/systemd/systemd_251.2.bb
@@ -12,7 +12,7 @@  inherit useradd pkgconfig meson perlnative update-rc.d update-alternatives qemu
 
 # As this recipe builds udev, respect systemd being in DISTRO_FEATURES so
 # that we don't build both udev and systemd in world builds.
-REQUIRED_DISTRO_FEATURES = "systemd"
+REQUIRED_DISTRO_FEATURES += "systemd"
 
 SRC_URI += "file://touchscreen.rules \
            file://00-create-volatile.conf \