Author: kolodko Date: Fri Feb 25 08:28:45 2005 GMT
Module: SOURCES Tag: HEAD
---- Log message:
- new from romke <romke (at) estrefa.pl>
---- Files affected:
SOURCES:
p910nd.init (NONE -> 1.1) (NEW), p910nd-makefile.patch (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: SOURCES/p910nd.init
diff -u /dev/null SOURCES/p910nd.init:1.1
--- /dev/null Fri Feb 25 09:28:45 2005
+++ SOURCES/p910nd.init Fri Feb 25 09:28:40 2005
@@ -0,0 +1,71 @@
+#!/bin/sh
+#
+# p910nd Start/Stop p910nd daemon.
+#
+# chkconfig: 2345 11 89
+# description: This shell script takes care of starting and stopping \
+# p910nd (port 9100+n printer daemon) \
+# This script only controls the one on port 9101. \
+# You can start others if you wish.
+#
+# processname: p910nd
+# config: /etc/sysconfig/p910nd
+
+# Source function library
+ /etc/rc.d/init.d/functions
+
+P910ND_PRINTERS="0" # 0 for lp0, 1 for lp1 and 2 for lp2
+P910ND_0_OPTIONS="" # for lp0
+P910ND_1_OPTIONS="-b" # ...etc
+
+# Get service config - may override defaults
+[ -f /etc/sysconfig/p910nd ] && . /etc/sysconfig/p910nd
+
+# See how we were called.
+case "$1" in
+ start)
+ # Start daemons.
+ for i in $P910ND_PRINTERS; do
+ if [ ! -f /var/lock/subsys/p910${i}d ]; then
+
+ msg_starting "p910${i}d"
+ OPTIONS="\$P910ND_${i}_OPTIONS"
+ OPTIONS=`eval echo $OPTIONS`
+ daemon p910nd ${OPTIONS} ${i}
+ RETVAL=$?
+ [ $RETVAL -eq 0 ] && touch /var/lock/subsys/p910${i}d
+ unset OPTIONS
+
+ else
+ msg_already_running "p910${i}d"
+ fi
+ done
+ ;;
+ stop)
+ # Stop daemons.
+ for i in $P910ND_PRINTERS; do
+ if [ -f /var/lock/subsys/p910${i}d ]; then
+ msg_stopping "p910${i}d"
+ killproc "p910${i}d"
+ rm -f /var/lock/subsys/p910${i}d
+ else
+ msg_not_running "p910${i}d"
+ fi
+ done
+ ;;
+ status)
+ for i in $P910ND_PRINTERS; do
+ status p910${i}d
+ done
+ ;;
+ restart)
+ $0 stop
+ $0 start
+ ;;
+ *)
+ echo "Usage: p910nd {start|stop|restart|status}"
+ exit 1
+esac
+unset i
+
+exit 0
================================================================
Index: SOURCES/p910nd-makefile.patch
diff -u /dev/null SOURCES/p910nd-makefile.patch:1.1
--- /dev/null Fri Feb 25 09:28:45 2005
+++ SOURCES/p910nd-makefile.patch Fri Feb 25 09:28:40 2005
@@ -0,0 +1,14 @@
+--- Makefile.orig 2005-02-03 14:41:19.000000000 +0100
++++ Makefile 2005-02-03 14:41:54.000000000 +0100
+@@ -3,8 +3,8 @@
+
+ # If you don't have it in /var/log/subsys, uncomment and define
+ #CFLAGS+=-DLOCKFILE_DIR=\"/var/log\"
+-LIBWRAP=-lwrap
++#LIBWRAP=-lwrap
+
+ p910nd: p910nd.c
+-# $(CC) -Wall $(CFLAGS) -o $@ p910nd.c
+- $(CC) -Wall $(CFLAGS) -DUSE_LIBWRAP -o $@ p910nd.c $(LIBWRAP)
++ $(CC) -Wall $(CFLAGS) -o $@ p910nd.c
++# $(CC) -Wall $(CFLAGS) -DUSE_LIBWRAP -o $@ p910nd.c $(LIBWRAP)
================================================================
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit