aboutsummaryrefslogtreecommitdiff
path: root/mail
diff options
context:
space:
mode:
authorChris Rees <crees@FreeBSD.org>2011-06-27 17:52:38 +0000
committerChris Rees <crees@FreeBSD.org>2011-06-27 17:52:38 +0000
commit726b65f320408dc22cc8159b2b8602cbab41804e (patch)
tree9b12a39b00a76b1440783fb6a2109aa6af3b9be7 /mail
parentf568ba617fd35b98dd84adc5ed512f2857ed277f (diff)
downloadports-726b65f320408dc22cc8159b2b8602cbab41804e.tar.gz
ports-726b65f320408dc22cc8159b2b8602cbab41804e.zip
Notes
Diffstat (limited to 'mail')
-rw-r--r--mail/dkfilter/Makefile14
-rw-r--r--mail/dkfilter/files/pkg-deinstall.in13
-rw-r--r--mail/dkfilter/files/pkg-install.in36
3 files changed, 3 insertions, 60 deletions
diff --git a/mail/dkfilter/Makefile b/mail/dkfilter/Makefile
index 16d432911c7a..089fc2570ce0 100644
--- a/mail/dkfilter/Makefile
+++ b/mail/dkfilter/Makefile
@@ -24,18 +24,10 @@ GNU_CONFIGURE= yes
USE_PERL5= yes
USE_RC_SUBR= dkfilter_in dkfilter_out
+USERS= ${DKFILTER_USERNAME}
+GROUPS= ${DKFILTER_GROUPNAME}
+
DKFILTER_USERNAME?= dkfilter
-DKFILTER_USERID?= 325
DKFILTER_GROUPNAME?= ${DKFILTER_USERNAME}
-DKFILTER_GROUPID?= ${DKFILTER_USERID}
-
-SUB_FILES= pkg-install pkg-deinstall
-SUB_LIST= USER=${DKFILTER_USERNAME} \
- UID=${DKFILTER_USERID} \
- GROUP=${DKFILTER_GROUPNAME} \
- GID=${DKFILTER_GROUPID}
-
-pre-install:
- ${SH} ${PKGINSTALL} ${PREFIX} PRE-INSTALL
.include <bsd.port.mk>
diff --git a/mail/dkfilter/files/pkg-deinstall.in b/mail/dkfilter/files/pkg-deinstall.in
deleted file mode 100644
index 65b9aec55e4c..000000000000
--- a/mail/dkfilter/files/pkg-deinstall.in
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/sh
-# $FreeBSD$
-
-if [ "$2" != "POST-DEINSTALL" ]; then
- exit 0
-fi
-
-USERNAME=%%USER%%
-
-if pw usershow "${USERNAME}" 2>/dev/null 1>&2; then
- echo "To delete ${USERNAME} user permanently, use 'pw userdel \"${USERNAME}\"'"
-fi
-exit 0
diff --git a/mail/dkfilter/files/pkg-install.in b/mail/dkfilter/files/pkg-install.in
deleted file mode 100644
index 75041933c0fd..000000000000
--- a/mail/dkfilter/files/pkg-install.in
+++ /dev/null
@@ -1,36 +0,0 @@
-#! /bin/sh
-#
-# $FreeBSD$
-
-PATH=/bin:/usr/bin:/usr/sbin
-
-case $2 in
-
-PRE-INSTALL)
- echo "---> Starting install script:"
-
- if [ -z "%%USER%%" -o -z "%%GROUP%%" -o \
- -z "%%UID%%" -o -z "%%GID%%" ]; then
- echo "ERROR: A required pragma was empty"
- exit 1
- fi
-
- # Create group if required
- if pw group show "%%GROUP%%" >/dev/null 2>&1; then
- echo "---> Using existing group \"%%GROUP%%\""
- else
- echo "---> Adding group \"%%GROUP%%\" (%%GID%%)"
- /usr/sbin/pw groupadd %%GROUP%% -g %%GID%% || exit 1
- fi
-
- # Create user if required
- if pw user show "%%USER%%" >/dev/null 2>&1; then
- echo "---> Using existing user \"%%USER%%\""
- else
- echo "---> Adding user \"%%USER%%\" (%%UID%%)"
- pw useradd "%%USER%%" -u "%%UID%%" -g "%%GROUP%%" -h - \
- -d "/nonexistent" -s "/sbin/nologin" -c "DK Filter Owner" || exit 1
- fi
- ;;
-
-esac