summaryrefslogtreecommitdiff
path: root/security/clamav/pkg-install
diff options
context:
space:
mode:
authorNorikatsu Shigemura <nork@FreeBSD.org>2003-06-18 09:43:05 +0000
committerNorikatsu Shigemura <nork@FreeBSD.org>2003-06-18 09:43:05 +0000
commit15e2ad28454dd207b113f6055df7bec5390ddf9c (patch)
tree46ef06c8cb0b0d8cfa795cf8929859450154e25d /security/clamav/pkg-install
parentNew port: games/quake2lnx (diff)
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/pkg-install')
-rw-r--r--security/clamav/pkg-install18
1 files changed, 13 insertions, 5 deletions
diff --git a/security/clamav/pkg-install b/security/clamav/pkg-install
index 4e257bc4ccf7..e99d15038e69 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