summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-core/systemd/systemd-systemctl-native
diff options
context:
space:
mode:
Diffstat (limited to 'meta-oe/recipes-core/systemd/systemd-systemctl-native')
-rwxr-xr-xmeta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl18
1 files changed, 18 insertions, 0 deletions
diff --git a/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl b/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
index 46e74e847..f74adf6c6 100755
--- a/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
+++ b/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
@@ -25,6 +25,14 @@ while [ $# != 0 ]; do
25 cmd_args="1" 25 cmd_args="1"
26 shift 26 shift
27 ;; 27 ;;
28 mask)
29 shift
30
31 action="$opt"
32 services="$1"
33 cmd_args="1"
34 shift
35 ;;
28 --root=*) 36 --root=*)
29 ROOT=${opt##--root=} 37 ROOT=${opt##--root=}
30 cmd_args="0" 38 cmd_args="0"
@@ -43,6 +51,16 @@ while [ $# != 0 ]; do
43done 51done
44 52
45for service in $services; do 53for service in $services; do
54 if [ "$action" = "mask" ]; then
55 if [ ! -d $ROOT/etc/systemd/system/ ]; then
56 mkdir -p $ROOT/etc/systemd/system/
57 fi
58 cmd="ln -s /dev/null $ROOT/etc/systemd/system/$service"
59 echo "$cmd"
60 $cmd
61 exit 0
62 fi
63
46 echo "Try to find location of $service..." 64 echo "Try to find location of $service..."
47 # find service file 65 # find service file
48 for p in $ROOT/etc/systemd/system \ 66 for p in $ROOT/etc/systemd/system \