Index: head/security/swatch/Makefile =================================================================== --- head/security/swatch/Makefile (revision 290859) +++ head/security/swatch/Makefile (revision 290860) @@ -1,33 +1,34 @@ # New ports collection makefile for: swatch # Date created: May 2 97 # Whom: jfitz # # $FreeBSD$ # PORTNAME= swatch PORTVERSION= 3.2.3 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= security sysutils MASTER_SITES= SF MAINTAINER= joseph@randomnetworks.com COMMENT= The Simple WATCHer and filter BUILD_DEPENDS= \ ${SITE_PERL}/Date/Format.pm:${PORTSDIR}/devel/p5-TimeDate \ ${SITE_PERL}/Date/Manip.pm:${PORTSDIR}/devel/p5-Date-Manip \ - ${SITE_PERL}/Date/Calc.pm:${PORTSDIR}/devel/p5-Date-Calc + ${SITE_PERL}/Date/Calc.pm:${PORTSDIR}/devel/p5-Date-Calc \ + ${SITE_PERL}/File/Tail.pm:${PORTSDIR}/devel/p5-File-Tail RUN_DEPENDS:= ${BUILD_DEPENDS} PERL_CONFIGURE= yes CONFIGURE_ARGS= INSTALLMAN1DIR=${PREFIX}/man/man1 USE_RC_SUBR= ${PORTNAME} MAN1= swatch.1 MAN3= Swatch::Actions.3 Swatch::Throttle.3 Swatch::Threshold.3 post-patch: ${FIND} ${WRKSRC} -name "*.orig" -delete .include Property changes on: head/security/swatch/Makefile ___________________________________________________________________ Modified: cvs2svn:cvs-rev ## -1 +1 ## -1.31 \ No newline at end of property +1.32 \ No newline at end of property Index: head/security/swatch/files/swatch.in =================================================================== --- head/security/swatch/files/swatch.in (revision 290859) +++ head/security/swatch/files/swatch.in (revision 290860) @@ -1,38 +1,45 @@ #!/bin/sh # # $FreeBSD$ # # PROVIDE: swatch # REQUIRE: DAEMON +# KEYWORD: shutdown # # To enable multiple instance of swatch, add lines like below to # /etc/rc.conf. # # swatch_enable="YES" # swatch_rules="1 2 3" # swatch_1_flags="--config-file=/rc --tail-file=/log --daemon --pid-file=/pid" # swatch_1_user="nobody" # swatch_1_chdir="/var/tmp" # swatch_1_pidfile="/pid" # swatch_2_flags="blah, blah" # swatch_3_flags="blah, blah" . /etc/rc.subr name=swatch rcvar=swatch_enable -command=%%PREFIX%%/bin/swatch -procname=%%LOCALBASE%%/bin/perl - load_rc_config ${name} +# set some defaults +: ${swatch_enable:="NO"} + +command=%%PREFIX%%/bin/swatch + if [ -n "${swatch_rules}" ]; then for i in ${swatch_rules}; do eval swatch_flags=\$swatch_${i}_flags + len=`echo "0${command} ${swatch_flags} (perl)0" | wc -c` + if [ $len -ge 255 ];then + procname=%%LOCALBASE%%/bin/perl + fi eval swatch_user=\$swatch_${i}_user eval swatch_chdir=\$swatch_${i}_chdir eval pidfile=\$swatch_${i}_pidfile run_rc_command "$1" done fi Property changes on: head/security/swatch/files/swatch.in ___________________________________________________________________ Modified: cvs2svn:cvs-rev ## -1 +1 ## -1.7 \ No newline at end of property +1.8 \ No newline at end of property