sh/gendepends.sh.in: fix detection of service scripts
We do not need to care about the path on the shebang line of a service script as long as the shebang line ends with "openrc-run". This fixes #119 and #120.
This commit is contained in:
parent
9bd63b5d4a
commit
50fccf47d4
@ -74,11 +74,22 @@ do
|
|||||||
|
|
||||||
# Only generate dependencies for OpenRC scripts
|
# Only generate dependencies for OpenRC scripts
|
||||||
read one two three <"$RC_SERVICE"
|
read one two three <"$RC_SERVICE"
|
||||||
[ "$one" = "#!@SBINDIR@/runscript" ] || \
|
case "$one" in
|
||||||
[ "$one" = "#!@SBINDIR@/openrc-run" ] || \
|
\#*/openrc-run) ;;
|
||||||
[ "$one" = "#!" -a "$two" = "@SBINDIR@/runscript" ] || \
|
\#*/runscript) ;;
|
||||||
[ "$one" = "#!" -a "$two" = "@SBINDIR@/openrc-run" ] || \
|
\#!)
|
||||||
continue
|
case "$two" in
|
||||||
|
*/openrc-run) ;;
|
||||||
|
*/runscript) ;;
|
||||||
|
*)
|
||||||
|
continue
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
continue
|
||||||
|
;;
|
||||||
|
esac
|
||||||
unset one two three
|
unset one two three
|
||||||
|
|
||||||
RC_SVCNAME=${RC_SERVICE##*/} ; export RC_SVCNAME
|
RC_SVCNAME=${RC_SERVICE##*/} ; export RC_SVCNAME
|
||||||
|
Loading…
Reference in New Issue
Block a user