summaryrefslogtreecommitdiffstats
path: root/meta-systemd/recipes-core
diff options
context:
space:
mode:
authorMartin Jansa <martin.jansa@gmail.com>2012-08-06 22:12:16 +0000
committerKoen Kooi <koen@dominion.thruhere.net>2012-08-08 09:02:04 +0200
commite32c470d32809be3d0249097214881021532fb2c (patch)
tree861805b0220d5f9021c6093894dd454cfd5d3a6a /meta-systemd/recipes-core
parentbc58a1e1c0f6e1c651568c68c47ab63e4cfc0e7b (diff)
downloadmeta-openembedded-e32c470d32809be3d0249097214881021532fb2c.tar.gz
systemd-compat-units: use systemctl mask
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Diffstat (limited to 'meta-systemd/recipes-core')
-rw-r--r--meta-systemd/recipes-core/systemd/systemd-compat-units.bb14
1 files changed, 10 insertions, 4 deletions
diff --git a/meta-systemd/recipes-core/systemd/systemd-compat-units.bb b/meta-systemd/recipes-core/systemd/systemd-compat-units.bb
index 2973208b1..aefd6a758 100644
--- a/meta-systemd/recipes-core/systemd/systemd-compat-units.bb
+++ b/meta-systemd/recipes-core/systemd/systemd-compat-units.bb
@@ -3,7 +3,7 @@ DESCRIPTION = "Units to make systemd work better with existing sysvinit scripts"
3LICENSE = "MIT" 3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58" 4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
5 5
6PR = "r16" 6PR = "r17"
7 7
8inherit allarch 8inherit allarch
9 9
@@ -38,11 +38,17 @@ SYSTEMD_DISABLED_SYSV_SERVICES = " \
38pkg_postinst_${PN} () { 38pkg_postinst_${PN} () {
39cd $D${sysconfdir}/init.d 39cd $D${sysconfdir}/init.d
40 40
41echo -n "Disabling the following sysv scripts: " 41echo "Disabling the following sysv scripts: "
42
43OPTS=""
44
45if [ -n "$D" ]; then
46 OPTS="--root=$D"
47fi
42 48
43for i in ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do 49for i in ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do
44 if [ \( -e $i -o $i.sh \) -a ! -e $D${base_libdir}/systemd/system/$i.service ] ; then 50 if [ \( -e $i -o $i.sh \) -a ! -e $D${sysconfdir}/systemd/system/$i.service ] ; then
45 echo -n "$i " ; ln -s /dev/null $D${base_libdir}/systemd/system/$i.service 51 echo -n "$i: " ; systemctl ${OPTS} mask $i.service
46 fi 52 fi
47done ; echo 53done ; echo
48} 54}