summaryrefslogtreecommitdiffstats
path: root/rules
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2012-07-29 21:20:25 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2012-08-24 11:53:34 +0200
commit5a167af30fd0c3db9d92613bd68820c6716eff5b (patch)
tree1a15891a41f14ead90d8f299271326fd8f5c4d91 /rules
parent7eb5bf20e497b283541b79b77846f2945a08e2db (diff)
downloadptxdist-5a167af30fd0c3db9d92613bd68820c6716eff5b.tar.gz
ptxdist-5a167af30fd0c3db9d92613bd68820c6716eff5b.tar.xz
rc-one: use systemd system-update mechanism
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'rules')
-rw-r--r--rules/rc-once.make5
-rw-r--r--rules/rc-once.postinst4
2 files changed, 4 insertions, 5 deletions
diff --git a/rules/rc-once.make b/rules/rc-once.make
index f01bbe9d8..aaed7443b 100644
--- a/rules/rc-once.make
+++ b/rules/rc-once.make
@@ -48,9 +48,8 @@ ifdef PTXCONF_INITMETHOD_SYSTEMD
@$(call install_alternative, rc-once, 0, 0, 0644, \
/lib/systemd/system/rc-once.service)
- @$(call install_alternative, rc-once, 0, 0, 0644, \
- /lib/systemd/system/rc-once.target)
- @$(call install_copy, rc-once, 0, 0, 0755, /etc/systemd/system)
+ @$(call install_link, rc-once, ../rc-once.service, \
+ /lib/systemd/system/system-update.target.wants/rc-once.service)
endif
@$(call install_copy, rc-once, 0, 0, 0755, /etc/rc.once.d)
diff --git a/rules/rc-once.postinst b/rules/rc-once.postinst
index f80a334cb..a7368bde1 100644
--- a/rules/rc-once.postinst
+++ b/rules/rc-once.postinst
@@ -1,6 +1,6 @@
#!/bin/sh
-if [ -f "$DESTDIR/lib/systemd/system/rc-once.target" ]; then
- ln -sf /lib/systemd/system/rc-once.target $DESTDIR/etc/systemd/system/default.target
+if [ -f "$DESTDIR/lib/systemd/system/rc-once.service" ]; then
+ ln -sf etc/rc.once.d $DESTDIR/system-update
fi