aboutsummaryrefslogtreecommitdiffstats
path: root/security/clamav
diff options
context:
space:
mode:
authornork <nork@FreeBSD.org>2003-06-18 17:43:05 +0800
committernork <nork@FreeBSD.org>2003-06-18 17:43:05 +0800
commit75b122cca08041d6c173232a3c0aa95b7a7770bf (patch)
tree72b2d12f015da6803b3ae8a1cc27780d9a7062aa /security/clamav
parent83f81a1030131b5219f60df430e56925fa960cf3 (diff)
downloadfreebsd-ports-graphics-75b122cca08041d6c173232a3c0aa95b7a7770bf.tar.gz
freebsd-ports-graphics-75b122cca08041d6c173232a3c0aa95b7a7770bf.tar.zst
freebsd-ports-graphics-75b122cca08041d6c173232a3c0aa95b7a7770bf.zip
o Add mirror site.
o Remove unnecsesary patches for current. o Add/remove users when installing/removing. o Set permissions on virus database dir. PR: ports/53305 Submitted by: Rob Evers<rob@debank.tv> Approved by: TERAMOTO Masahiro <markun@onohara.to> (maintainer)
Diffstat (limited to 'security/clamav')
-rw-r--r--security/clamav/Makefile17
-rw-r--r--security/clamav/pkg-install18
-rw-r--r--security/clamav/pkg-plist1
3 files changed, 24 insertions, 12 deletions
diff --git a/security/clamav/Makefile b/security/clamav/Makefile
index 93ecbdb71aa..d051d1a3ce5 100644
--- a/security/clamav/Makefile
+++ b/security/clamav/Makefile
@@ -9,7 +9,9 @@ PORTNAME= clamav
PORTVERSION= 0.54
PORTREVISION= 1
CATEGORIES= security
-MASTER_SITES= http://clamav.elektrapro.com/stable/
+MASTER_SITES= http://clamav.elektrapro.com/stable/ \
+ http://clamav.essentkabel.com/stable/
+
MAINTAINER= markun@onohara.to
COMMENT= Command line virus scanner written entirely in C
@@ -36,12 +38,13 @@ MAN8= clamd.8
.include <bsd.port.pre.mk>
-.if ${OSVERSION} >= 500000
-EXTRA_PATCHES= ${FILESDIR}/patch5-*
-.endif
-
pre-install:
- @${ECHO} "==> Creating custom user to run clamav..."
-# ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
+ @${ECHO} "===> Creating custom user to run clamav..."
+ ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
+
+post-install:
+ @${ECHO} "===> Setting permissions..."
+ @${SETENV} PKG_PREFIX=${PREFIX} ${sh} \
+ ${SH} ${PKGINSTALL} ${PREFIX} POST-INSTALL
.include <bsd.port.post.mk>
diff --git a/security/clamav/pkg-install b/security/clamav/pkg-install
index 4e257bc4ccf..e99d15038e6 100644
--- a/security/clamav/pkg-install
+++ b/security/clamav/pkg-install
@@ -1,11 +1,9 @@
#!/bin/sh
-if [ "$2" != "PRE-INSTALL" ]; then
- exit 0
-fi
+if [ "$2" = "PRE-INSTALL" ]; then
-USER?=clamav
-GROUP?=clamav
+USER=clamav
+GROUP=clamav
if ! pw groupshow "$GROUP" 2>/dev/null 1>&2; then
if pw groupadd $GROUP; then
@@ -27,4 +25,14 @@ if ! pw usershow "$USER" 2>/dev/null 1>&2; then
exit 1
fi
fi
+fi
+
+if [ "$2" = "POST-INSTALL" ]; then
+ chown -R clamav:clamav ${PKG_PREFIX}/share/clamav
+fi
+
+if [ "$2" != "POST-INSTALL" ] && [ "$2" != "PRE-INSTALL" ]; then
+ exit 0
+fi
+
exit 0
diff --git a/security/clamav/pkg-plist b/security/clamav/pkg-plist
index b919db1eb40..c561a92c33a 100644
--- a/security/clamav/pkg-plist
+++ b/security/clamav/pkg-plist
@@ -11,3 +11,4 @@ lib/libclamav.a
share/clamav/viruses.db
share/clamav/viruses.db2
@dirrm share/clamav
+@unexec rmuser -y clamav