aboutsummaryrefslogtreecommitdiffstats
path: root/irc/inspircd
diff options
context:
space:
mode:
authorjgh <jgh@FreeBSD.org>2012-06-15 03:28:02 +0800
committerjgh <jgh@FreeBSD.org>2012-06-15 03:28:02 +0800
commit72e73604366b5410da02d167e6fa3c7becba24b7 (patch)
tree6a15a0baec2a198f40ba8e94081182523a43a9d4 /irc/inspircd
parent7aa1889da0bb57a00f80b617e58ada60aa48ed25 (diff)
downloadfreebsd-ports-gnome-72e73604366b5410da02d167e6fa3c7becba24b7.tar.gz
freebsd-ports-gnome-72e73604366b5410da02d167e6fa3c7becba24b7.tar.zst
freebsd-ports-gnome-72e73604366b5410da02d167e6fa3c7becba24b7.zip
- use USERS/GROUPS framework
- remove pkg-deinstall and move cleanup instructions into pkg-plist - pet portlint on pkg-plist for mode and group warnings PR: ports/168821 Submitted by: jgh@ Approved by: maintainer, feld@feld.me
Diffstat (limited to 'irc/inspircd')
-rw-r--r--irc/inspircd/Makefile17
-rw-r--r--irc/inspircd/files/inspircd.in8
-rw-r--r--irc/inspircd/files/pkg-deinstall.in32
-rw-r--r--irc/inspircd/pkg-plist5
4 files changed, 8 insertions, 54 deletions
diff --git a/irc/inspircd/Makefile b/irc/inspircd/Makefile
index 43f856bbd800..5b49c8e97b65 100644
--- a/irc/inspircd/Makefile
+++ b/irc/inspircd/Makefile
@@ -7,7 +7,7 @@
PORTNAME= inspircd
PORTVERSION= 2.0.5
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= irc
MASTER_SITES= http://cloud.github.com/downloads/inspircd/inspircd/
DISTNAME= InspIRCd-${PORTVERSION}
@@ -21,22 +21,15 @@ USE_BZIP2= yes
USE_RC_SUBR= ${PORTNAME}
MAKEFILE= BSDmakefile
-USERS= ${INSPIRCD_USR}
-GROUPS= ${INSPIRCD_GRP}
+USERS= ircd
+GROUPS= ircd
+INSPIRCD_UID= 72
-INSPIRCD_USR?= ircd
-INSPIRCD_UID?= 72
-INSPIRCD_GRP?= ircd
-INSPIRCD_GID?= 72
INSPIRCD_RUN?= /var/run/${PORTNAME}
INSPIRCD_LOG?= /var/log/${PORTNAME}/ircd.log
-SUB_LIST+= PORTNAME=${PORTNAME} \
- INSPIRCD_USR=${INSPIRCD_USR} \
- INSPIRCD_GRP=${INSPIRCD_GRP} \
+SUB_LIST+= PORTNAME=${PORTNAME} \
INSPIRCD_LOG=${INSPIRCD_LOG} \
INSPIRCD_RUN=${INSPIRCD_RUN}
-PLIST_SUB+= INSPIRCD_GRP=${INSPIRCD_GRP}
-SUB_FILES+= pkg-deinstall
# Configure script is written in perl
USE_PERL5_BUILD=yes
diff --git a/irc/inspircd/files/inspircd.in b/irc/inspircd/files/inspircd.in
index 9844084f452a..9bae6619fba2 100644
--- a/irc/inspircd/files/inspircd.in
+++ b/irc/inspircd/files/inspircd.in
@@ -20,10 +20,6 @@
# %%PORTNAME%%_pidfile="%%INSPIRCD_RUN%%/%%PORTNAME%%.pid"
# -- location of pidfile: must match setting
# in ${%%PORTNAME%%_conffile}
-# %%PORTNAME%%_user="%%INSPIRCD_USR%%"
-# -- user to run %%PORTNAME%% as
-# %%PORTNAME%%_group="%%INSPIRCD_GRP%%"
-# -- group to run %%PORTNAME%% as
# %%PORTNAME%%_logfile="%%INSPIRCD_LOG%%"
# -- file %%PORTNAME%% writes logs to
#
@@ -37,8 +33,8 @@ load_rc_config ${name}
: ${%%PORTNAME%%_enable="NO"}
: ${%%PORTNAME%%_config="%%ETCDIR%%/%%PORTNAME%%.conf"}
: ${%%PORTNAME%%_pidfile="%%INSPIRCD_RUN%%/%%PORTNAME%%.pid"}
-: ${%%PORTNAME%%_user="%%INSPIRCD_USR%%"}
-: ${%%PORTNAME%%_group="%%INSPIRCD_GRP%%"}
+: ${%%PORTNAME%%_user=ircd}
+: ${%%PORTNAME%%_group=ircd}
: ${%%PORTNAME%%_logfile="%%INSPIRCD_LOG%%"}
command=%%PREFIX%%/bin/%%PORTNAME%%
diff --git a/irc/inspircd/files/pkg-deinstall.in b/irc/inspircd/files/pkg-deinstall.in
deleted file mode 100644
index f182a03917b6..000000000000
--- a/irc/inspircd/files/pkg-deinstall.in
+++ /dev/null
@@ -1,32 +0,0 @@
-#!/bin/sh
-#
-# $FreeBSD$
-#
-
-inspircd_usr=%%INSPIRCD_USR%%
-inspircd_grp=%%INSPIRCD_GRP%%
-etcdir=%%ETCDIR%%
-inspircd_name=%%PORTNAME%%
-
-case $2 in
- POST-DEINSTALL)
-
- cat <<EOMSG
-
-The $inspircd_name port has been deleted. If you are not
-upgrading and don't intend to use $inspircd_name any more
-then you may wish to delete the $inspircd_usr account,
-and the $inspircd_grp group together with the configuration
-directory ${etcdir}; which can be done with the
-following commands:
-
- # pw userdel -n $inspircd_usr
- # rm -rf $etcdir
-EOMSG
- echo
- ;;
-esac
-
-#
-# That's All Folks!
-#
diff --git a/irc/inspircd/pkg-plist b/irc/inspircd/pkg-plist
index 8195542ae524..c590d4591e74 100644
--- a/irc/inspircd/pkg-plist
+++ b/irc/inspircd/pkg-plist
@@ -206,8 +206,6 @@ lib/inspircd/modules/m_xline_db.so
@dirrm lib/inspircd/logs
@dirrm lib/inspircd/data
@dirrm lib/inspircd
-@mode 640
-@group %%INSPIRCD_GRP%%
@unexec if cmp -s %D/%%ETCDIR%%/inspircd.censor.example %D/%%ETCDIR%%/inspircd.censor; then rm -f %D/%%ETCDIR%%/inspircd.censor; fi
%%ETCDIR%%/inspircd.censor.example
@exec if [ ! -f %B/inspircd.censor ] ; then cp -p %D/%F %B/inspircd.censor; fi
@@ -241,6 +239,5 @@ lib/inspircd/modules/m_xline_db.so
@unexec if cmp -s %D/%%ETCDIR%%/opers.conf.example %D/%%ETCDIR%%/opers.conf; then rm -f %D/%%ETCDIR%%/opers.conf; fi
%%ETCDIR%%/opers.conf.example
@exec if [ ! -f %B/opers.conf.example ] ; then cp -p %D/%F %B/opers.conf.example; fi
+@unexec echo "If permanently removing software, you may wish to remove the configuration directory by running \"rm -rf %%LOCALBASE%%/%%ETCDIR%%\""
@dirrmtry %%ETCDIR%%
-@mode
-@group