1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51
|
#!/bin/sh -e
#
# bootup for gom 0.29.99+: initialize mixer(s)
#
# (c) 1998-2000 Stephan A Suerken <absurd@debian.org>
#
#
# Silent exits
#
gom_cmd=/usr/bin/gom-ct
sound_driver=/proc/sound
no_auto_init=/etc/gom/NO_AUTO_INIT
# gom.deb is removed but not purged
[ -x ${gom_cmd} ] || exit 0
# No sound driver (yet)
[ -e ${sound_driver} ] || exit 0
# Explicit configuration
[ ! -e ${no_auto_init} ] || exit 0
#
# Initialization
#
case "$1" in
# At this point, gom is installed properly and the (oss) sound
# driver is present.
# Won't fail even if configuration is invalid.
start|restart|reload|force-reload)
echo -n "Gom initializing audio mixer(s)..."
if ${gom_cmd} --quiet --initialize >/dev/null 2>&1 ;
# if ${gom_cmd} --quiet --initialize ;
then echo "done."
else echo "some errors. Check 'gom --initialize'."
fi
;;
stop)
;;
*)
echo "Usage: /etc/init.d/gom {start|restart|reload|force-reload|stop}" >&2
echo
echo " start|restart|reload|force-reload initializes audio mixer(s)." >&2
echo " stop does nothing." >&2
exit 1
;;
esac
exit 0
|