START/STOP values must be specified in the init script
authorMike Baker <mbm@openwrt.org>
Thu, 10 May 2007 10:38:53 +0000 (10:38 +0000)
committerMike Baker <mbm@openwrt.org>
Thu, 10 May 2007 10:38:53 +0000 (10:38 +0000)
SVN-Revision: 7164

package/base-files/files/etc/rc.common
package/br2684ctl/files/br2684ctl
package/busybox/files/cron
package/busybox/files/httpd
package/busybox/files/telnet
package/dropbear/files/dropbear.init

index 7ca107817dcfe904306f2439640d049c376e3f93..453cdbf33ac3e6e658bdf7377b81e16f21a7e200 100755 (executable)
@@ -3,8 +3,6 @@
 
 . $IPKG_INSTROOT/etc/functions.sh
 
-START=50
-
 start() {
        return 0
 }
@@ -34,13 +32,14 @@ shutdown() {
 disable() {
        name="$(basename "${initscript}")"
        rm -f "$IPKG_INSTROOT"/etc/rc.d/S??$name
+       rm -f "$IPKG_INSTROOT"/etc/rc.d/K??$name
 }
 
 enable() {
        name="$(basename "${initscript}")"
        disable
-       ln -s "/etc/init.d/$name" "$IPKG_INSTROOT/etc/rc.d/S${START}${name##S[0-9][0-9]}"
-       [ "$STOP" ] && ln -s "/etc/init.d/$name" "$IPKG_INSTROOT/etc/rc.d/K${START}${name##K[0-9][0-9]}"
+       [ "$START" ] && ln -s "/etc/init.d/$name" "$IPKG_INSTROOT/etc/rc.d/S${START}${name##S[0-9][0-9]}"
+       [ "$STOP"  ] && ln -s "/etc/init.d/$name" "$IPKG_INSTROOT/etc/rc.d/K${START}${name##K[0-9][0-9]}"
 }
 
 enabled() {
index b3ea34efcd6f767ef6756b3f97c3a43fae7ebd49..b121c7a4a5d82575b57637a509d06315a738ff71 100755 (executable)
@@ -1,4 +1,6 @@
 #!/bin/sh /etc/rc.common
+START=50
+
 stop() {
        killall br2684ctl 2>/dev/null >/dev/null
        sleep 1
index e78d02332cd3881d06ae6d905793709123e0f286..cf0f725d3e23b587bb053ac2c0dde5a6c80dd899 100755 (executable)
@@ -1,5 +1,6 @@
 #!/bin/sh /etc/rc.common
 # Copyright (C) 2006 OpenWrt.org
+START=50
 
 start () {
        mkdir -p /var/spool/cron
index e4f5f48e9cb966a7228ca4fc4fbd8a7be1c08e18..35b7f62948821547b4f27a45d141edefcb462933 100755 (executable)
@@ -1,5 +1,6 @@
 #!/bin/sh /etc/rc.common
 # Copyright (C) 2006 OpenWrt.org
+START=50
 
 start() {
        include /lib/network
index c61fe73ad5c43abe7294d1d56c5cfe169295a06d..58025840298e6cb058a83e65fb47699af4aed754 100755 (executable)
@@ -1,5 +1,6 @@
 #!/bin/sh /etc/rc.common
 # Copyright (C) 2006 OpenWrt.org
+START=50
 
 start() {
        if      [ \! -f /etc/passwd ] || \
index b629c1e48e9dae0e0b39455bedbd5893356196f2..f671df787e92e49bc4c94f8409cfd7a038f1c758 100755 (executable)
@@ -1,5 +1,6 @@
 #!/bin/sh /etc/rc.common
 # Copyright (C) 2006 OpenWrt.org
+START=50
 # Copyright (C) 2006 Carlos Sobrinho
 
 config_cb() {