diff options
-rw-r--r-- | security/racoon/Makefile | 3 | ||||
-rw-r--r-- | security/racoon/files/racoon.sh | 18 | ||||
-rw-r--r-- | security/racoon2/Makefile | 3 | ||||
-rw-r--r-- | security/racoon2/files/racoon.sh | 18 |
4 files changed, 42 insertions, 0 deletions
diff --git a/security/racoon/Makefile b/security/racoon/Makefile index 5aec98aaab68..a6ac14807697 100644 --- a/security/racoon/Makefile +++ b/security/racoon/Makefile @@ -7,6 +7,7 @@ PORTNAME= racoon PORTVERSION= 20020507a +PORTREVISION= 1 CATEGORIES= security net MASTER_SITES= ftp://ftp.kame.net/pub/kame/misc/ @@ -37,6 +38,8 @@ pre-configure: (cd ${WRKSRC}/../libipsec; make) post-install: + @${SED} 's@%PREFIX%@${LOCALBASE}@g' ${FILESDIR}/racoon.sh > ${PREFIX}/etc/rc.d/racoon.sh + @${CHMOD} +x ${PREFIX}/etc/rc.d/racoon.sh @if [ -z `/sbin/sysctl -a | ${GREP} -q ipsec && echo ipsec` ]; then \ ${ECHO_MSG} "WARNING: IPsec feature is disabled on this host"; \ ${ECHO_MSG} " You must build the kernel if you want to run racoon on the host"; \ diff --git a/security/racoon/files/racoon.sh b/security/racoon/files/racoon.sh new file mode 100644 index 000000000000..d6a5c1b3098a --- /dev/null +++ b/security/racoon/files/racoon.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +case "$1" in + start) + if [ -x %PREFIX%/sbin/racoon ]; then + %PREFIX%/sbin/racoon -f %PREFIX%/etc/racoon/racoon.conf && echo -n ' racoon' + fi + ;; + + stop) + /usr/bin/killall racoon && echo -n ' racoon' + ;; + + *) + echo "Usage: `basename $0` { start | stop }" + exit 64 + ;; +esac diff --git a/security/racoon2/Makefile b/security/racoon2/Makefile index 5aec98aaab68..a6ac14807697 100644 --- a/security/racoon2/Makefile +++ b/security/racoon2/Makefile @@ -7,6 +7,7 @@ PORTNAME= racoon PORTVERSION= 20020507a +PORTREVISION= 1 CATEGORIES= security net MASTER_SITES= ftp://ftp.kame.net/pub/kame/misc/ @@ -37,6 +38,8 @@ pre-configure: (cd ${WRKSRC}/../libipsec; make) post-install: + @${SED} 's@%PREFIX%@${LOCALBASE}@g' ${FILESDIR}/racoon.sh > ${PREFIX}/etc/rc.d/racoon.sh + @${CHMOD} +x ${PREFIX}/etc/rc.d/racoon.sh @if [ -z `/sbin/sysctl -a | ${GREP} -q ipsec && echo ipsec` ]; then \ ${ECHO_MSG} "WARNING: IPsec feature is disabled on this host"; \ ${ECHO_MSG} " You must build the kernel if you want to run racoon on the host"; \ diff --git a/security/racoon2/files/racoon.sh b/security/racoon2/files/racoon.sh new file mode 100644 index 000000000000..d6a5c1b3098a --- /dev/null +++ b/security/racoon2/files/racoon.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +case "$1" in + start) + if [ -x %PREFIX%/sbin/racoon ]; then + %PREFIX%/sbin/racoon -f %PREFIX%/etc/racoon/racoon.conf && echo -n ' racoon' + fi + ;; + + stop) + /usr/bin/killall racoon && echo -n ' racoon' + ;; + + *) + echo "Usage: `basename $0` { start | stop }" + exit 64 + ;; +esac |