1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-05 22:43:24 +00:00
freebsd-ports/net/netatalk-asun/files/patch-ab
Stefan Bethke 4fe21ce59c - obey CFLAGS
- put pid files in /var/run
- make start-up script work on different PREFIX
1998-11-24 14:13:47 +00:00

32 lines
924 B
Plaintext

--- rc.atalk.freebsd.orig Tue Nov 24 13:08:44 1998
+++ rc.atalk.freebsd Tue Nov 24 13:56:05 1998
@@ -0,0 +1,28 @@
+#
+# AppleTalk daemons. Make sure not to start atalkd in the background:
+# its data structures must have time to stablize before running the
+# other processes.
+#
+PREFIX=/`expr $0 : '/\(.*\)/etc/rc.d/netatalk.sh'`
+if [ "x${PREFIX}" = "x/" ]; then
+ printf "\nnetatalk: Cannot determine PREFIX.\n" >&2
+ exit 64
+fi
+HOSTNAME=`hostname|sed 's/\..*$//'`
+
+case $1 in
+ start) echo -n ' netatalk'
+ ${PREFIX}/libexec/atalkd
+ ${PREFIX}/bin/nbprgstr -p 4 ${HOSTNAME}:Workstation &
+ ${PREFIX}/bin/nbprgstr -p 4 ${HOSTNAME}:netatalk &
+ ${PREFIX}/libexec/papd
+ ${PREFIX}/libexec/afpd -s ${PREFIX}/etc/AppleVolumes.system \
+ -f ${PREFIX}/etc/AppleVolumes.default
+ ;;
+ stop) for i in afpd papd atalkd; do
+ if [ -f /var/run/$i.pid ]; then
+ kill `cat /var/run/$i.pid`
+ fi
+ done
+ ;;
+esac