summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorDirk Meyer <dinoex@FreeBSD.org>2004-02-18 20:24:40 +0000
committerDirk Meyer <dinoex@FreeBSD.org>2004-02-18 20:24:40 +0000
commit42331cf4ddaabd611d4a079b4d3f57e8a96a23e6 (patch)
treebd3800a4a31eb0895cf66935eb8c2077f5b2eb62 /security
parentRespect PTHREAD_{CFLAGS,LIBS}. (diff)
- Unbreak threading issue
PR: 63022 Submitted by: rob@debank.tv - Use fixStaleSocket by default - Add clamav user to mail group (for exim users) - clean up DOCSDIR variable PR: 63022 Submitted by: rob@debank.tv Suggested by: eik
Notes
Notes: svn path=/head/; revision=101346
Diffstat (limited to 'security')
-rw-r--r--security/clamav-devel/Makefile17
-rw-r--r--security/clamav-devel/files/clamav-clamd.sh10
-rw-r--r--security/clamav-devel/pkg-descr2
-rw-r--r--security/clamav-devel/pkg-install1
-rw-r--r--security/clamav-devel/pkg-plist8
5 files changed, 17 insertions, 21 deletions
diff --git a/security/clamav-devel/Makefile b/security/clamav-devel/Makefile
index fc760fa11b85..ad7fdabc5736 100644
--- a/security/clamav-devel/Makefile
+++ b/security/clamav-devel/Makefile
@@ -7,6 +7,7 @@
PORTNAME= clamav
PORTVERSION= 20040210
+PORTREVISION= 1
CATEGORIES= security
MASTER_SITES= http://clamav.sourceforge.net/snapshot/
PKGNAMESUFFIX= -devel
@@ -47,6 +48,7 @@ CLAMAVUSER?= clamav
CLAMAVGROUP?= clamav
CLAMAV_CLAMD_SOCKET?= /var/run/clamav/clamd
CLAMAV_MILTER_SOCKET?= /var/run/clamav/clmilter.sock
+DOCSDIR?= ${PREFIX}/share/doc/${PORTNAME}${PKGNAMESUFFIX}
PLIST_SUB+= CLAMAVUSER="${CLAMAVUSER}"
PLIST_SUB+= CLAMAVGROUP="${CLAMAVGROUP}"
@@ -67,14 +69,11 @@ SED_CONF= -E -e 's|^\#?(Example)$$|\#\1|' \
-e 's|^\#?(Checks)$$|\#\1|' \
-e 's|^\#?(DatabaseDirectory) .*$$|\1 ${DATADIR}|' \
-e 's|^\#?(DatabaseOwner) .*$$|\1 ${CLAMAVUSER}|' \
- -e 's|^\#?(UpdateLogFile) .*$$|\1 /var/log/clamav/freshclam.log|'
+ -e 's|^\#?(UpdateLogFile) .*$$|\1 /var/log/clamav/freshclam.log|' \
+ -e 's|^\#?(FixStaleSocket)$$|\1|'
.include <bsd.port.pre.mk>
-.if ${OSVERSION} >= 502102
-FORBIDDEN= "Links against conflicting thread libraries"
-.endif
-
USE_RC_SUBR= yes
RC_DIR= ${PREFIX}/etc/rc.d
RC_SUFX= .sh
@@ -98,7 +97,11 @@ PLIST_SUB+= CLAMAV-MILTER:="@comment "
.endif
post-patch:
+.if ${OSVERSION} >= 502102
+ @${REINPLACE_CMD} -e 's|-lc_r|${PTHREAD_LIBS}|g' ${WRKSRC}/configure
+.else
@${REINPLACE_CMD} -e 's|-pthread|${PTHREAD_LIBS}|g' ${WRKSRC}/configure
+.endif
@${REINPLACE_CMD} -e 's|/usr/lib/sendmail|/usr/sbin/sendmail|g' \
-e 's|<malloc.h>|<stdlib.h>|' \
${WRKSRC}/clamav-milter/clamav-milter.c
@@ -118,8 +121,8 @@ pre-install:
${SETENV} PKG_PREFIX=${PREFIX} \
${SH} ${PKGINSTALL} ${PREFIX} PRE-INSTALL
.if !defined(NOPORTDOCS)
- @${MKDIR} ${DOCSDIR}${PKGNAMESUFFIX}
- @${INSTALL_DATA} ${WRKSRC}/docs/*pdf ${DOCSDIR}${PKGNAMESUFFIX}
+ @${MKDIR} ${DOCSDIR}
+ @${INSTALL_DATA} ${WRKSRC}/docs/*pdf ${DOCSDIR}
.endif
post-install:
diff --git a/security/clamav-devel/files/clamav-clamd.sh b/security/clamav-devel/files/clamav-clamd.sh
index add634772cea..243a3fba871b 100644
--- a/security/clamav-devel/files/clamav-clamd.sh
+++ b/security/clamav-devel/files/clamav-clamd.sh
@@ -26,16 +26,6 @@ pidfile=/var/run/clamav/clamd.pid
required_dirs=%%DATADIR%%
required_files=%%PREFIX%%/etc/clamav.conf
-start_precmd=start_precmd
-
-start_precmd()
-{
- if [ -S "$clamd_socket" ]; then
- warn "Stale socket $clamd_socket removed."
- rm "$clamd_socket"
- fi
-}
-
stop_postcmd=stop_postcmd
stop_postcmd()
diff --git a/security/clamav-devel/pkg-descr b/security/clamav-devel/pkg-descr
index 0b742a8459e5..ee8e04ab8b6f 100644
--- a/security/clamav-devel/pkg-descr
+++ b/security/clamav-devel/pkg-descr
@@ -4,3 +4,5 @@ database is kept up to date. It also detects polymorphic
viruses, scans compressed files and is supported by AMaViS.
Optionally you can use the clamav-milter interface to connect
clamav with sendmail.
+
+WWW: http://clamav.sourceforge.net/
diff --git a/security/clamav-devel/pkg-install b/security/clamav-devel/pkg-install
index bb13314c848a..bab656901a04 100644
--- a/security/clamav-devel/pkg-install
+++ b/security/clamav-devel/pkg-install
@@ -29,6 +29,7 @@ if ! pw usershow "${CLAMAVUSER}" 2>/dev/null 1>&2; then
-c "Clam Antivirus"; \
then
echo "===> Added user \"${CLAMAVUSER}\"."
+ pw groupmod mail -m ${CLAMAVUSER}
else
echo "===> Adding user \"${CLAMAVUSER}\" failed..."
exit 1
diff --git a/security/clamav-devel/pkg-plist b/security/clamav-devel/pkg-plist
index aed505240645..6db1d4fdfe32 100644
--- a/security/clamav-devel/pkg-plist
+++ b/security/clamav-devel/pkg-plist
@@ -11,9 +11,9 @@ include/clamav.h
lib/libclamav.so.1
lib/libclamav.so
lib/libclamav.a
-%%PORTDOCS%%%%DOCSDIR%%-devel/clamav-mirror-howto.pdf
-%%PORTDOCS%%%%DOCSDIR%%-devel/clamdoc.pdf
-%%PORTDOCS%%%%DOCSDIR%%-devel/signatures.pdf
+%%PORTDOCS%%%%DOCSDIR%%/clamav-mirror-howto.pdf
+%%PORTDOCS%%%%DOCSDIR%%/clamdoc.pdf
+%%PORTDOCS%%%%DOCSDIR%%/signatures.pdf
@unexec if cmp -s %D/etc/clamav.conf %D/etc/clamav.conf.default; then rm -f %D/etc/clamav.conf; fi
etc/clamav.conf.default
@exec [ -f %B/clamav.conf ] || cp %B/%f %B/clamav.conf
@@ -29,4 +29,4 @@ etc/freshclam.conf.default
@unexec rmdir %D/%%DATADIR%% 2>/dev/null || true
@unexec rmdir /var/run/clamav 2>/dev/null || true
@unexec rmdir /var/log/clamav 2>/dev/null || true
-%%PORTDOCS%%@dirrm %%DOCSDIR%%-devel
+%%PORTDOCS%%@dirrm %%DOCSDIR%%