aboutsummaryrefslogtreecommitdiff
path: root/mail/drac/files
diff options
context:
space:
mode:
authorNorikatsu Shigemura <nork@FreeBSD.org>2003-03-26 02:25:52 +0000
committerNorikatsu Shigemura <nork@FreeBSD.org>2003-03-26 02:25:52 +0000
commit13011e478e533c9ff335157865ba92993cf34cec (patch)
tree2904cce4e7f18b748f1edc377cee4f482b4b3799 /mail/drac/files
parentf801162f9468ecef6ff5ac2fb428620df03582ec (diff)
downloadports-13011e478e533c9ff335157865ba92993cf34cec.tar.gz
ports-13011e478e533c9ff335157865ba92993cf34cec.zip
o Update to 1.12[1].
o Clean up rc script to rc.conf configuratable. Acording to the POLA, if you don't set it, this feature will have no effect (same behavior before now). Pointed out by: Mats Dufberg <dufberg@narnia.pp.se> [1]
Notes
Notes: svn path=/head/; revision=77467
Diffstat (limited to 'mail/drac/files')
-rw-r--r--mail/drac/files/dracd.sh24
-rw-r--r--mail/drac/files/patch-aa31
2 files changed, 36 insertions, 19 deletions
diff --git a/mail/drac/files/dracd.sh b/mail/drac/files/dracd.sh
index 902ccdf7ae9c..0490ac2f9114 100644
--- a/mail/drac/files/dracd.sh
+++ b/mail/drac/files/dracd.sh
@@ -1,16 +1,30 @@
#!/bin/sh
-if ! PREFIX=$(expr $0 : "\(/.*\)/etc/rc\.d/$(basename $0)\$"); then
- echo "$0: Cannot determine the PREFIX" >&2
- exit 1
+if ! PREFIX=$(/bin/expr $0 : "\(/.*\)/etc/rc\.d/${0##*/}\$"); then
+ echo "$0: Cannot determine the PREFIX" >&2
+ exit 64
+fi
+
+if [ -r /etc/defaults/rc.conf ]; then
+ . /etc/defaults/rc.conf
+ source_rc_confs
+elif [ -r /etc/rc.conf ]; then
+ . /etc/rc.conf
fi
case "$1" in
start)
- [ -x ${PREFIX}/sbin/rpc.dracd ] && ${PREFIX}/sbin/rpc.dracd && echo -n ' dracd'
+ case ${dracd_enable:-NO} in
+ [Yy][Ee][Ss])
+ ${dracd_program:-${PREFIX}/sbin/rpc.dracd} ${drac_flags} && echo -n ' dracd'
+ ;;
+ esac
;;
stop)
- killall rpc.dracd >/dev/null 2>&1 && echo -n ' dracd'
+ case ${dracd_enable:-NO} in
+ [Yy][Ee][Ss])
+ /usr/bin/killall rpc.dracd >/dev/null 2>&1 && echo -n ' dracd'
+ esac
;;
*)
echo "Usage: `basename $0` {start|stop}" >&2
diff --git a/mail/drac/files/patch-aa b/mail/drac/files/patch-aa
index 46a8066b6d86..59785f6101bc 100644
--- a/mail/drac/files/patch-aa
+++ b/mail/drac/files/patch-aa
@@ -1,5 +1,5 @@
---- Makefile.orig Mon Nov 20 16:35:16 2000
-+++ Makefile Wed Jan 2 22:39:40 2002
+--- Makefile.orig Mon Jan 13 05:45:12 2003
++++ Makefile Wed Mar 26 08:58:22 2003
@@ -5,9 +5,10 @@
# Paths
@@ -7,44 +7,47 @@
-INSTALL = /usr/ucb/install
-EBIN = /usr/local/sbin
-MAN = /usr/local/man/man
-+INSTALL = install
++INSTALL? = install
+EBIN = ${PREFIX}/sbin
+MAN = ${PREFIX}/man/man
+ETC_DIR = ${PREFIX}/etc
# OS-Dependant settings
-@@ -33,20 +34,40 @@
+@@ -33,22 +34,42 @@
# -DCIDR_KEY # keys in CIDR format
# -DTERM_KD # keys and data nul-terminated
-DEFS = -DTI_RPC -DFCNTL_LOCK -DSYSINFO
+.if defined(WITH_TI_RPC)
-+RPCFLAGS= -DTI_RPC
++DEFS+= -DTI_RPC
+.else
-+RPCFLAGS= -DSOCK_RPC
++DEFS+= -DSOCK_RPC
+.endif
+
+.if defined(WITH_POSTFIX) || defined(WITH_POSTFIX_DB3)
-+DEFS= $(RPCFLAGS) -DFLOCK_LOCK -DGETHOST -DDASH_C -DTERM_KD
++DEFS+= -DFLOCK_LOCK -DGETHOST -DDASH_C -DTERM_KD
+.elif defined(WITH_EXIM)
-+DEFS= $(RPCFLAGS) -DFLOCK_LOCK -DGETHOST -DDASH_C -DTERM_KD -DREQ_HASH -DCIDR_KEY
++DEFS+= -DFLOCK_LOCK -DGETHOST -DDASH_C -DTERM_KD -DREQ_HASH -DCIDR_KEY
+.else
-+DEFS= $(RPCFLAGS) -DFLOCK_LOCK -DGETHOST -DDASH_C
++DEFS+= -DFLOCK_LOCK -DGETHOST -DDASH_C
+.endif
+.if defined(WITH_FOREGROUND)
+DEFS+= -DRPC_SVC_FG
+.endif
# Compiler flags
- CC = cc
+-CC = cc
++CC? = cc
RANLIB = :
--CFLAGS = $(DEFS) -g -I/usr/local/src/db/db-3.1.17/build_unix
-+CFLAGS = $(DEFS) -g -I${PREFIX}/include -DDBFILE=\"$(ETC_DIR)/dracd.db\" -DALFILE=\"$(ETC_DIR)/dracd.allow\"
+-CFLAGS = $(DEFS) -g -I/usr/local/src/db/db-4.1.25/build_unix
++CFLAGS+= $(DEFS) -g -I${PREFIX}/include -DDBFILE=\"$(ETC_DIR)/dracd.db\" -DALFILE=\"$(ETC_DIR)/dracd.allow\"
+ #CFLAGS = $(DEFS) -g -I/usr/local/src/db/db-3.1.17/build_unix
#CFLAGS = $(DEFS) -g -I/usr/local/src/db/db-2.4.14/Unix
#CFLAGS = $(DEFS) -g -I/usr/local/src/db/db.1.85/PORT/sunos.5.2/include
--LDLIBS = -L/usr/local/src/db/db-3.1.17/build_unix -lnsl -ldb
-+LDLIBS =
+-LDLIBS = -L/usr/local/src/db/db-4.1.25/build_unix -lnsl -ldb-4.1
++LDLIBS =
+ #LDLIBS = -L/usr/local/src/db/db-3.1.17/build_unix -lnsl -ldb
#LDLIBS = -L/usr/local/src/db/db-2.4.14/Unix -lnsl -ldb
#LDLIBS = -L/usr/local/src/db/db.1.85/PORT/sunos.5.2 -lnsl -ldb
-TSTLIBS = -L. -ldrac -lnsl