]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Slackware uses /etc/rc.d/rc.$service instead of just $service,
authorRoy Marples <roy@marples.name>
Fri, 2 Aug 2013 09:10:38 +0000 (09:10 +0000)
committerRoy Marples <roy@marples.name>
Fri, 2 Aug 2013 09:10:38 +0000 (09:10 +0000)
so configure doesn't find those. This patch overrides the
defaults for SERVICEEXISTS, SERVICECMD, and SERVICESTATUS.
Thanks to Robby Workman.

configure

index 523fc03c202e8c5b8751b01f7abc0b00a4dc7300..00dbfdb294fd8fcaf44fc5d794f5c5275e6720b6 100755 (executable)
--- a/configure
+++ b/configure
@@ -629,6 +629,17 @@ if [ -z "$SERVICECMD" ]; then
                echo "no"
        fi
 fi
+if [ -z "$SERVICECMD"  ]; then
+       printf "Checking for Slackware ... "
+       if [ -e /etc/slackware-version -a -d /etc/rc.d ]; then
+               SERVICEEXISTS="[ -x /etc/rc.d/rc.\$1 ]"
+               SERVICECMD="/etc/rc.d/rc.\$1 \$2"
+               SERVICESTATUS="/etc/rc.d/rc.\$1 status 1>/dev/null 2>&1"
+               echo "yes"
+       else
+               echo "no"
+       fi
+fi
 if [ -z "$SERVICECMD" ]; then
        for x in /etc/init.d/rc.d /etc/rc.d /etc/init.d; do
                printf "Checking for $x ... "