summaryrefslogtreecommitdiffstats
path: root/abs/core/runit/runit.install
diff options
context:
space:
mode:
authorCecil Hugh Watson <knoppmyth@gmail.com>2009-09-26 01:57:08 (GMT)
committerCecil Hugh Watson <knoppmyth@gmail.com>2009-09-26 01:57:08 (GMT)
commit7b29169fff9e7c624890c5edffe85def8a293136 (patch)
tree47753889faa3a2063b66d1c7e7681e703eb1b39a /abs/core/runit/runit.install
parentc491dea779dac29afff3578bf8245943817c2339 (diff)
downloadlinhes_pkgbuild-7b29169fff9e7c624890c5edffe85def8a293136.zip
linhes_pkgbuild-7b29169fff9e7c624890c5edffe85def8a293136.tar.gz
linhes_pkgbuild-7b29169fff9e7c624890c5edffe85def8a293136.tar.bz2
LinHES 6.01.00
Diffstat (limited to 'abs/core/runit/runit.install')
-rwxr-xr-xabs/core/runit/runit.install40
1 files changed, 16 insertions, 24 deletions
diff --git a/abs/core/runit/runit.install b/abs/core/runit/runit.install
index 4652368..1728bc6 100755
--- a/abs/core/runit/runit.install
+++ b/abs/core/runit/runit.install
@@ -4,9 +4,10 @@ pre_install () {
if [ ! -f /sbin/halt-init ]
then
mv /sbin/halt /sbin/halt-init
+ mv /sbin/shutdown /sbin/shutdown-init
+fi
rm -f /sbin/reboot
rm -f /sbin/poweroff
-fi
}
@@ -14,41 +15,32 @@ pre_upgrade () {
if [ ! -f /sbin/halt-init ]
then
mv /sbin/halt /sbin/halt-init
+fi
+
+if [ ! -f /sbin/shutdown-init ]
+then
+ mv /sbin/shutdown /sbin/shutdown-init
+fi
rm -f /sbin/reboot
rm -f /sbin/poweroff
-fi
}
post_install () {
-
- mkdir /var/service
- ln -s /etc/sv/tty* /var/service
- servicelist="acpid cron frontend lircd ntpd alsa-utils avahi dbus portmap sshd"
- for i in $servicelist
- do
- ln -s /etc/sv/$i /var/service/$i
- done
-
- ln -s /sbin/halt.script /sbin/halt
- ln -s /sbin/reboot.script /sbin/reboot
- ln -s /sbin/poweroff.script /sbin/poweroff
- ln -s /sbin/halt-init /sbin/reboot.init
- ln -s /sbin/halt-init /sbin/poweroff.init
-
-
+ mkdir /var/service
+ [ -e /sbin/halt ] || ln -s /sbin/halt.script /sbin/halt
+ [ -e /sbin/reboot ] || ln -s /sbin/reboot.script /sbin/reboot
+ [ -e /sbin/poweroff ] || ln -s /sbin/poweroff.script /sbin/poweroff
+ [ -e /sbin/reboot.init ] || ln -s /sbin/halt-init /sbin/reboot.init
+ [ -e /sbin/poweroff.init ] || ln -s /sbin/halt-init /sbin/poweroff.init
+ [ -e /sbin/shutdown ] || ln -s /sbin/shutdown.script /sbin/shutdown
}
# arg 1: the new package version
# arg 2: the old package version
post_upgrade(){
- ln -s /sbin/halt.script /sbin/halt
- ln -s /sbin/reboot.script /sbin/reboot
- ln -s /sbin/poweroff.script /sbin/poweroff
- ln -s /sbin/halt-init /sbin/reboot.init
- ln -s /sbin/halt-init /sbin/poweroff.init
-
+ /bin/true
}
op=$1