summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2011-12-13 10:43:43 +0000
committerKoen Kooi <koen@dominion.thruhere.net>2011-12-15 09:25:07 +0100
commit2cba3b024407bf0cdba09b27e06eb207ea77a754 (patch)
tree72791a1455f01645fc0d80bbdc0cf239f19220c8
parente550e77ca9956911ec1212984b1aac2d05e4e650 (diff)
downloadmeta-openembedded-2cba3b024407bf0cdba09b27e06eb207ea77a754.tar.gz
systemd-systemctl-native: add support to recursive services
Some services can reference others for installation thought the Also key; systemctl now handles it calling itself recursively for each service. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
-rw-r--r--meta-oe/recipes-core/systemd/systemd-systemctl-native.bb2
-rwxr-xr-xmeta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl8
2 files changed, 10 insertions, 0 deletions
diff --git a/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb b/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb
index 3ee757e15..dcd67ee54 100644
--- a/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb
+++ b/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb
@@ -3,6 +3,8 @@ DESCRIPTION = "Wrapper to enable of systemd services"
3LICENSE = "MIT" 3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58" 4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
5 5
6PR = "r1"
7
6inherit native 8inherit native
7 9
8SRC_URI = "file://systemctl" 10SRC_URI = "file://systemctl"
diff --git a/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl b/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
index 1fc77fd92..54c1a18bf 100755
--- a/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
+++ b/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
@@ -49,3 +49,11 @@ for r in $wanted_by; do
49 ln -s $service_file $ROOT/etc/systemd/system/$r.wants 49 ln -s $service_file $ROOT/etc/systemd/system/$r.wants
50 echo "Enabled $service for $wanted_by." 50 echo "Enabled $service for $wanted_by."
51done 51done
52
53# call us for the other required scripts
54also=$(grep Also $ROOT/$service_file \
55 | sed 's,Also=,,g' \
56 | tr ',' '\n')
57for a in $also; do
58 $0 --root=$ROOT enable $a
59done