Last change
on this file since 2167cfe was 2167cfe, checked in by William Harrington <kb0iic@…>, 11 years ago |
bootscripts are the scripts used for the sysvinit book.
|
-
Property mode
set to
100644
|
File size:
1002 bytes
|
Rev | Line | |
---|
[2167cfe] | 1 | #!/bin/bash
|
---|
| 2 | # Begin $rc_base/init.d/gpm
|
---|
| 3 |
|
---|
| 4 | # Based on sysklogd script from LFS-3.1 and earlier.
|
---|
| 5 | # Rewritten by Gerard Beekmans - gerard@linuxfromscratch.org
|
---|
| 6 | # GPM specific parts by Mark Hymers - markh@linuxfromscratch.org
|
---|
| 7 |
|
---|
| 8 | #$LastChangedBy: dnicholson $
|
---|
| 9 | #$Date: 2006-10-11 02:42:17 -0500 (Wed, 11 Oct 2006) $
|
---|
| 10 |
|
---|
| 11 | . /etc/sysconfig/rc
|
---|
| 12 | . $rc_functions
|
---|
| 13 |
|
---|
| 14 | pidfile=/var/run/gpm.pid
|
---|
| 15 |
|
---|
| 16 | if [ -f /etc/sysconfig/mouse ]
|
---|
| 17 | then
|
---|
| 18 | . /etc/sysconfig/mouse
|
---|
| 19 | fi
|
---|
| 20 |
|
---|
| 21 | if [ -z "$MDEVICE" ] || [ -z "$PROTOCOL" ]
|
---|
| 22 | then
|
---|
| 23 | echo "Please create an /etc/sysconfig/mouse file containing"
|
---|
| 24 | echo "MDEVICE and PROTOCOL values"
|
---|
| 25 | exit 1;
|
---|
| 26 | fi
|
---|
| 27 |
|
---|
| 28 | case "$1" in
|
---|
| 29 | start)
|
---|
| 30 | boot_mesg "Starting gpm..."
|
---|
| 31 | loadproc -p $pidfile /usr/sbin/gpm -m $MDEVICE -t $PROTOCOL $GPMOPTS
|
---|
| 32 | ;;
|
---|
| 33 |
|
---|
| 34 | stop)
|
---|
| 35 | boot_mesg "Stopping gpm..."
|
---|
| 36 | killproc -p $pidfile /usr/sbin/gpm
|
---|
| 37 | ;;
|
---|
| 38 |
|
---|
| 39 | restart)
|
---|
| 40 | $0 stop
|
---|
| 41 | sleep 1
|
---|
| 42 | $0 start
|
---|
| 43 | ;;
|
---|
| 44 |
|
---|
| 45 | status)
|
---|
| 46 | statusproc -p $pidfile /usr/sbin/gpm
|
---|
| 47 | ;;
|
---|
| 48 |
|
---|
| 49 | *)
|
---|
| 50 | echo "Usage: $0 {start|stop|restart|status}"
|
---|
| 51 | exit 1
|
---|
| 52 | ;;
|
---|
| 53 | esac
|
---|
| 54 |
|
---|
| 55 | # End $rc_base/init.d/gpm
|
---|
Note:
See
TracBrowser
for help on using the repository browser.