1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
|
#! /bin/sh
# $Id: gpsd.hotplug.wrapper 4669 2008-01-21 15:07:00Z esr $
#debian addition:
[ ! -r /etc/default/gpsd ] || . /etc/default/gpsd
[ "$START_DAEMON" = "true" ] || exit 0
[ "$USBAUTO" = "true" ] || exit 0
if [ "$ACTION" == "remove" ] ; then
if [ $(echo $DEVLINKS | grep -q /dev/gps) ] ; then
exec /lib/udev/gpsd.hotplug "$ACTION" "$DEVNAME"
fi
exit 0
fi
. /lib/udev/hotplug.functions
# wait for /usr & /var to be mounted
wait_for_file /usr/bin/python && \
wait_for_file /var/run && \
exec /lib/udev/gpsd.hotplug "$ACTION" "$DEVNAME"
|