aboutsummaryrefslogtreecommitdiff
path: root/mail/simscan
diff options
context:
space:
mode:
authorBryan Drewery <bdrewery@FreeBSD.org>2014-04-01 14:30:04 +0000
committerBryan Drewery <bdrewery@FreeBSD.org>2014-04-01 14:30:04 +0000
commit1b4bb08f3902c4eef52dde95c50506de09357a0d (patch)
treee34e4bab3a0de1b6cbffcc84bfb808ae61b5e2c3 /mail/simscan
parent5416b34e37a3e63bcc2112eda60f92ae3c32e854 (diff)
downloadports-1b4bb08f3902c4eef52dde95c50506de09357a0d.tar.gz
ports-1b4bb08f3902c4eef52dde95c50506de09357a0d.zip
Notes
Diffstat (limited to 'mail/simscan')
-rw-r--r--mail/simscan/Makefile18
-rw-r--r--mail/simscan/files/pkg-install.in20
-rw-r--r--mail/simscan/pkg-plist7
3 files changed, 16 insertions, 29 deletions
diff --git a/mail/simscan/Makefile b/mail/simscan/Makefile
index e44f8513ec8a..c526b8225344 100644
--- a/mail/simscan/Makefile
+++ b/mail/simscan/Makefile
@@ -21,8 +21,8 @@ GROUPS= ${USERS}
WORKDIR?= ${QMAIL_PREFIX}/${PORTNAME}
QMAIL_QUEUE= ${QMAIL_PREFIX}/bin/qmail-queue
-SUB_FILES= pkg-message \
- pkg-install
+SUB_FILES= pkg-message
+
SUB_LIST= QMAIL_PREFIX=${QMAIL_PREFIX} \
SIMSCAN_DIR=${PORTNAME}
PLIST_SUB= QMAIL_PREFIX=${QMAIL_PREFIX} \
@@ -41,7 +41,6 @@ PASSTHRU_DESC= Pass Spam Thru, Do Not Reject (required SPAMD)
HEADERS_DESC= Add a Received Line With Versions of Scanners
DSPAM_DESC= Turn on DSPAM scanning
-NO_STAGE= yes
.include <bsd.port.pre.mk>
CONFIGURE_ARGS=--enable-clamavdb-path=/var/db/clamav \
@@ -127,6 +126,10 @@ post-patch:
${WRKSRC}/configure
@${ECHO_CMD} "${CC} ${CFLAGS}" > ${WRKSRC}/cdb/conf-cc
@${ECHO_CMD} "${CC} ${STRIP} ${LDFLAGS}" > ${WRKSRC}/cdb/conf-ld
+ @${ECHO_CMD} ${STAGEDIR}${PREFIX} > ${WRKSRC}/cdb/conf-home
+ @${REINPLACE_CMD} -e 's|@qmaildir@|$$(DESTDIR)@qmaildir@|' \
+ -e 's|@workdir@|$$(DESTDIR)@workdir@|' \
+ ${WRKSRC}/Makefile.in
pre-configure:
@${ECHO_MSG} ""
@@ -148,17 +151,14 @@ pre-configure:
@${ECHO_MSG} ""
pre-install:
- @${REINPLACE_CMD} -e 's|nobody|simscan|g' ${WRKSRC}/Makefile
- @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
+ ${MKDIR} ${STAGEDIR}${QMAIL_PREFIX}/bin
post-install:
- @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
.if ${PORT_OPTIONS:MDOCS}
- @${MKDIR} ${DOCSDIR}
+ ${MKDIR} ${STAGEDIR}${DOCSDIR}
.for i in ${PORTDOCS}
- @${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DOCSDIR}
.endfor
.endif
- @${CAT} ${PKGMESSAGE}
.include <bsd.port.post.mk>
diff --git a/mail/simscan/files/pkg-install.in b/mail/simscan/files/pkg-install.in
deleted file mode 100644
index b2307e0ed73c..000000000000
--- a/mail/simscan/files/pkg-install.in
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/bin/sh
-#
-# $FreeBSD$
-
-USER=simscan
-GROUP=${USER}
-SIMDIR=%%QMAIL_PREFIX%%/%%SIMSCAN_DIR%%
-
-if [ "$2" = "POST-INSTALL" ]; then
-
- if [ ! -d "$SIMDIR" ]; then
- /bin/mkdir -p "$SIMDIR" || exit 1
- /usr/sbin/chown "$USER:$GROUP" "$SIMDIR" || exit 1
- /bin/chmod 0750 "$SIMDIR" || exit 1
- /bin/chmod 04711 %%QMAIL_PREFIX%%/bin/simscan
- /usr/sbin/chown $USER:$GROUP %%QMAIL_PREFIX%%/bin/simscan %%QMAIL_PREFIX%%/bin/simscanmk
- fi
-fi
-
-exit 0
diff --git a/mail/simscan/pkg-plist b/mail/simscan/pkg-plist
index ee246cc68e98..fe91c3ffa341 100644
--- a/mail/simscan/pkg-plist
+++ b/mail/simscan/pkg-plist
@@ -1,4 +1,11 @@
@cwd %%QMAIL_PREFIX%%
+@owner simscan
+@group simscan
bin/simscanmk
+@mode 04711
bin/simscan
+@mode
+@owner root
+@group wheel
+@exec install -d -o simscan -g simscan -m 0750 %D/%%SIMSCAN_DIR%%
@dirrmtry %%SIMSCAN_DIR%%