summaryrefslogtreecommitdiffstats
path: root/meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2014-09-03 15:09:20 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-09-03 11:09:07 +0100
commit23c943628249712eae86704218050f7ecdfa61a1 (patch)
treee76f9aaee133ee7e082e5829d4afa2cb6710290e /meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb
parent9105e9e3c498d1a9552bc98ce1003cd0afc615c0 (diff)
downloadpoky-23c943628249712eae86704218050f7ecdfa61a1.tar.gz
modutils-initscripts: mask modutils in case of systemd
We need to prevent the init script from running via systemd because its functionality has been implemented interanlly in systemd. In a systemd system, we can add configuration files under /etc/modules-load.d/ to make things work. (From OE-Core rev: 8fc304a59bb3977146645fe2c3570a3aaa4aac39) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb')
-rw-r--r--meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb10
1 files changed, 10 insertions, 0 deletions
diff --git a/meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb b/meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb
index 125f5fb073..7031ba142c 100644
--- a/meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb
+++ b/meta/recipes-kernel/modutils-initscripts/modutils-initscripts.bb
@@ -18,3 +18,13 @@ do_install () {
18 install -d ${D}${sysconfdir}/init.d/ 18 install -d ${D}${sysconfdir}/init.d/
19 install -m 0755 ${WORKDIR}/modutils.sh ${D}${sysconfdir}/init.d/ 19 install -m 0755 ${WORKDIR}/modutils.sh ${D}${sysconfdir}/init.d/
20} 20}
21
22DEPENDS_append = " ${@bb.utils.contains('DISTRO_FEATURES','systemd','systemd-systemctl-native','',d)}"
23pkg_postinst_${PN} () {
24 if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
25 if [ -n "$D" ]; then
26 OPTS="--root=$D"
27 fi
28 systemctl $OPTS mask modutils.service
29 fi
30}