summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mail/sid-milter/MESSAGE4
-rw-r--r--mail/sid-milter/Makefile11
-rw-r--r--mail/sid-milter/PLIST8
-rwxr-xr-xmail/sid-milter/files/sid-filter.sh38
-rwxr-xr-xmail/sid-milter/files/sid-milter.sh24
5 files changed, 50 insertions, 35 deletions
diff --git a/mail/sid-milter/MESSAGE b/mail/sid-milter/MESSAGE
index 59c3a7bedc4..d1698012120 100644
--- a/mail/sid-milter/MESSAGE
+++ b/mail/sid-milter/MESSAGE
@@ -1,5 +1,5 @@
===========================================================================
-$NetBSD: MESSAGE,v 1.1.1.1 2010/03/12 22:42:55 pettai Exp $
+$NetBSD: MESSAGE,v 1.2 2012/04/04 22:09:49 pettai Exp $
sid-milter is now installed.
The documentation can be found at ${PREFIX}/share/doc/sid-milter/
@@ -9,7 +9,7 @@ for setting up sid-milter.
At a minmium you will need to specify:
- sidmilter_flags="-p socketfile -d domain"
+ sidfilter_flags="-p socketfile -d domain"
in your /etc/rc.conf.
diff --git a/mail/sid-milter/Makefile b/mail/sid-milter/Makefile
index b632ee05daa..7208c4a0c5c 100644
--- a/mail/sid-milter/Makefile
+++ b/mail/sid-milter/Makefile
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.2 2011/12/05 08:07:52 pettai Exp $
+# $NetBSD: Makefile,v 1.3 2012/04/04 22:09:49 pettai Exp $
#
DISTNAME= sid-milter-1.0.0
+PKGREVISION= 1
CATEGORIES= mail
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=sid-milter/}
@@ -18,7 +19,7 @@ USE_BUILTIN.libmilter= NO
USE_TOOLS+= gm4
MAKE_ENV+= M4=${M4:Q}
PTHREAD_OPTS+= require
-RCD_SCRIPTS= sid-milter
+RCD_SCRIPTS= sid-filter
SIDDOC= ${PREFIX}/share/doc/sid-milter
@@ -28,7 +29,7 @@ SUBST_FILES.libs= sid-filter/Makefile.m4
SUBST_SED.libs= -e "s|@LMBASE@|${BUILDLINK_PREFIX.libmilter}|g"
SUBST_MESSAGE.libs= Fixing paths.
-INSTALLATION_DIRS= bin include lib ${PKGMANDIR}/cat3 ${PKGMANDIR}/cat8
+INSTALLATION_DIRS= bin include lib ${PKGMANDIR}/man3 ${PKGMANDIR}/man8
post-extract:
${CP} ${FILESDIR}/sid-filter.m4 ${WRKSRC}/sid-filter/Makefile.m4
@@ -43,11 +44,11 @@ do-install:
${INSTALL_LIB} ${WRKSRC}/${SIDWORK}/libar/libar.a \
${DESTDIR}${PREFIX}/lib
${INSTALL_MAN} ${WRKSRC}/${SIDWORK}/libar/ar.0 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/cat3/
+ ${DESTDIR}${PREFIX}/${PKGMANDIR}/man3/
${INSTALL_PROGRAM} ${WRKSRC}/${SIDWORK}/sid-filter/sid-filter \
${DESTDIR}${PREFIX}/bin
${INSTALL_MAN} ${WRKSRC}/${SIDWORK}/sid-filter/sid-filter.0 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/cat8/
+ ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8/
${INSTALL_DATA} ${WRKSRC}/FEATURES ${DESTDIR}${SIDDOC}
${INSTALL_DATA} ${WRKSRC}/INSTALL ${DESTDIR}${SIDDOC}
${INSTALL_DATA} ${WRKSRC}/KNOWNBUGS ${DESTDIR}${SIDDOC}
diff --git a/mail/sid-milter/PLIST b/mail/sid-milter/PLIST
index 0344a68c99e..6b1d9bcce99 100644
--- a/mail/sid-milter/PLIST
+++ b/mail/sid-milter/PLIST
@@ -1,9 +1,9 @@
-@comment $NetBSD: PLIST,v 1.1.1.1 2010/03/12 22:42:55 pettai Exp $
+@comment $NetBSD: PLIST,v 1.2 2012/04/04 22:09:49 pettai Exp $
bin/sid-filter
include/sm-marid.h
lib/libar.a
-man/cat3/ar.0
-man/cat8/sid-filter.0
+man/man3/ar.0
+man/man8/sid-filter.0
share/doc/sid-milter/FEATURES
share/doc/sid-milter/INSTALL
share/doc/sid-milter/KNOWNBUGS
@@ -14,4 +14,4 @@ share/doc/sid-milter/RELEASE_NOTES
share/doc/sid-milter/rfc4406.txt
share/doc/sid-milter/rfc4407.txt
share/doc/sid-milter/rfc4408.txt
-share/examples/rc.d/sid-milter
+share/examples/rc.d/sid-filter
diff --git a/mail/sid-milter/files/sid-filter.sh b/mail/sid-milter/files/sid-filter.sh
new file mode 100755
index 00000000000..006acb23bf1
--- /dev/null
+++ b/mail/sid-milter/files/sid-filter.sh
@@ -0,0 +1,38 @@
+#!@RCD_SCRIPTS_SHELL@
+#
+# $NetBSD: sid-filter.sh,v 1.1 2012/04/04 22:09:49 pettai Exp $
+#
+# PROVIDE: sidfilter
+# REQUIRE: DAEMON
+
+if [ -f /etc/rc.subr ]; then
+ . /etc/rc.subr
+fi
+
+name="sidfilter"
+rcvar=$name
+command="@PREFIX@/bin/sid-filter"
+pidfile="@VARBASE@/run/sid-filter/${name}.pid"
+command_args="-p local:@VARBASE@/run/sid-filter/${name}.sock -P ${pidfile} -l"
+start_precmd="sidfilter_precmd"
+
+sidfilter_precmd()
+{
+ if [ ! -d @VARBASE@/run/sid-filter ]; then
+ @MKDIR@ @VARBASE@/run/sid-filter
+ @CHMOD@ 0750 @VARBASE@/run/sid-filter
+ @CHOWN@ smmsp:smmsp @VARBASE@/run/sid-filter
+ fi
+
+ if [ -f @VARBASE@/run/sid-filter/${name}.sock ]; then
+ @RM@ -f @VARBASE@/run/sid-filter/${name}.sock
+ fi
+}
+
+if [ -f /etc/rc.subr ]; then
+ load_rc_config $name
+ run_rc_command "$1"
+else
+ echo -n " ${name}"
+ ${command} ${sidfilter_flags} ${command_args}
+fi
diff --git a/mail/sid-milter/files/sid-milter.sh b/mail/sid-milter/files/sid-milter.sh
deleted file mode 100755
index 006eee3b5a5..00000000000
--- a/mail/sid-milter/files/sid-milter.sh
+++ /dev/null
@@ -1,24 +0,0 @@
-#!@RCD_SCRIPTS_SHELL@
-#
-# $NetBSD: sid-milter.sh,v 1.1.1.1 2010/03/12 22:42:55 pettai Exp $
-#
-# PROVIDE: sidfilter
-# REQUIRE: DAEMON
-
-if [ -f /etc/rc.subr ]; then
- . /etc/rc.subr
-fi
-
-name="sidfilter"
-rcvar=$name
-command="@PREFIX@/bin/sid-filter"
-pidfile="/var/run/sid-filter.pid"
-command_args="-l -P ${pidfile}"
-
-if [ -f /etc/rc.subr ]; then
- load_rc_config $name
- run_rc_command "$1"
-else
- echo -n " ${name}"
- ${command} ${sidfilter_flags} ${command_args}
-fi