From: Roy Marples Date: Fri, 6 Mar 2015 10:03:25 +0000 (+0000) Subject: Support runit (untested) X-Git-Tag: v6.8.0~46 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=648b5c64478baaab23926809e723ce5425cea42f;p=thirdparty%2Fdhcpcd.git Support runit (untested) --- diff --git a/dhcpcd-run-hooks.in b/dhcpcd-run-hooks.in index 34c7dbcf..8094920e 100644 --- a/dhcpcd-run-hooks.in +++ b/dhcpcd-run-hooks.in @@ -280,6 +280,12 @@ detect_init() elif [ -x /sbin/service ]; then _service_exists="/sbin/service \$1 >/dev/null 2>&1" _service_cmd="/sbin/service \$1 \$2" + elif [ -x /bin/sv ]; then + _service_exists="/bin/sv status \1 >/dev/null 2>&1" + _service_cmd="/bin/sv \$1 \$2" + elif [ -x /usr/bin/sv ]; then + _service_exists="/usr/bin/sv status \1 >/dev/null 2>&1" + _service_cmd="/usr/bin/sv \$1 \$2" elif [ -e /etc/slackware-version -a -d /etc/rc.d ]; then _service_exists="[ -x /etc/rc.d/rc.\$1 ]" _service_cmd="/etc/rc.d/rc.\$1 \$2"