summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--GIDs1
-rw-r--r--UIDs1
-rw-r--r--net-mgmt/ifgraph/Makefile9
-rw-r--r--net-mgmt/ifgraph/files/pkg-deinstall.in21
-rw-r--r--net-mgmt/ifgraph/files/pkg-install.in30
5 files changed, 7 insertions, 55 deletions
diff --git a/GIDs b/GIDs
index 5b5cb1d3b654..8da2659a73e6 100644
--- a/GIDs
+++ b/GIDs
@@ -164,3 +164,4 @@ minbif:*:926:
kumofs:*:927:
nslcd:*:928:
activemq:*:929:
+ifgraph:*:930:
diff --git a/UIDs b/UIDs
index 3638c3c585d5..6cf56fd8e52c 100644
--- a/UIDs
+++ b/UIDs
@@ -174,3 +174,4 @@ minbif:*:926:926::0:0:Minbif Daemon User:/nonexistent:/usr/sbin/nologin
kumofs:*:927:927::0:0:kumofs daemon:/nonexistent:/usr/sbin/nologin
nslcd:*:928:928::0:0:nslcd daemon:/nonexistent:/usr/sbin/nologin
activemq:*:929:929::0:0:ActiveMQ Daemon:/nonexistent:/sbin/nologin
+ifgraph:*:930:930::0:0:ifGraph:/nonexistent:/sbin/nologin
diff --git a/net-mgmt/ifgraph/Makefile b/net-mgmt/ifgraph/Makefile
index 4d0dc4e0a5be..399cfe16d8e7 100644
--- a/net-mgmt/ifgraph/Makefile
+++ b/net-mgmt/ifgraph/Makefile
@@ -26,17 +26,14 @@ PKGMESSAGE= ${WRKDIR}/pkg-message
PKGINSTALL= ${WRKDIR}/pkg-install
PKGDEINSTALL= ${WRKDIR}/pkg-deinstall
-IFGRAPH_USER= ifgraph
-IFGRAPH_GROUP= ifgraph
+USERS= ifgraph
+GROUPS= ifgraph
PLFILES= find-if.pl ifgraph.pl makegraph.pl
DOCFILES= CHANGELOG INSTALACAO INSTALL TODO LICENSE.TXT MUDANCAS
SUB_FILES= crontab pkg-deinstall pkg-install pkg-message
-SUB_LIST= USER=${IFGRAPH_USER} GROUP=${IFGRAPH_GROUP} PERL=${PERL}
-
-pre-install:
- @ ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
+SUB_LIST= USER=${USERS} PERL=${PERL}
do-install:
.for plfile in ${PLFILES}
diff --git a/net-mgmt/ifgraph/files/pkg-deinstall.in b/net-mgmt/ifgraph/files/pkg-deinstall.in
index 8c58d2e1603f..6868a7f93bef 100644
--- a/net-mgmt/ifgraph/files/pkg-deinstall.in
+++ b/net-mgmt/ifgraph/files/pkg-deinstall.in
@@ -1,6 +1,6 @@
#!/bin/sh
#
-# $FreeBSD: /tmp/pcvs/ports/net-mgmt/ifgraph/files/pkg-deinstall.in,v 1.1 2010-01-24 18:51:29 lth Exp $
+# $FreeBSD: /tmp/pcvs/ports/net-mgmt/ifgraph/files/pkg-deinstall.in,v 1.2 2010-08-12 13:20:34 lth Exp $
#
PATH=/bin:/usr/bin:/usr/sbin
@@ -16,23 +16,4 @@ DEINSTALL)
;;
-POST-DEINSTALL)
- echo '---> Starting post-deinstall script:'
-
- if [ -f %%PREFIX%%/etc/ifgraph.conf -o \
- -d %%PREFIX%%/ifgraph -o \
- -d %%PREFIX%%/var/ifgraph ]; then
- echo '---> You seem to have made some custom ifGraph configuration.'
- echo '---> - The "%%USER%%" user and "%%GROUP%%" group were therefore not deleted.'
- echo '---> - You may delete them with "pw groupdel %%GROUP%%; pw userdel %%USER%%".'
-
- else
- echo '---> Removing group "%%GROUP%%"'
- /usr/sbin/pw groupdel -n %%GROUP%%
- echo '---> Removing user "%%USER%%"'
- echo 'y' | /usr/sbin/pw userdel -n %%USER%%
- fi
-
- ;;
-
esac
diff --git a/net-mgmt/ifgraph/files/pkg-install.in b/net-mgmt/ifgraph/files/pkg-install.in
index 9cd574dd232d..56a52171ba89 100644
--- a/net-mgmt/ifgraph/files/pkg-install.in
+++ b/net-mgmt/ifgraph/files/pkg-install.in
@@ -1,39 +1,11 @@
#!/bin/sh
#
-# $FreeBSD: /tmp/pcvs/ports/net-mgmt/ifgraph/files/pkg-install.in,v 1.1 2010-01-24 18:51:29 lth Exp $
+# $FreeBSD: /tmp/pcvs/ports/net-mgmt/ifgraph/files/pkg-install.in,v 1.2 2010-08-12 13:20:34 lth Exp $
#
PATH=/bin:/usr/bin:/usr/sbin
case $2 in
-
-PRE-INSTALL)
- echo "---> Starting pre-install script:"
-
- if [ -z "%%USER%%" -o \
- -z "%%GROUP%%" ]; then
- echo "ERROR: A required pragma was empty"
- exit 1
- fi
-
- if pw showgroup "%%GROUP%%" 2>/dev/null; then
- echo "---> Using existing group \"%%GROUP%%\""
- else
- echo "---> Adding group \"%%GROUP%%\""
- pw addgroup %%GROUP%% -h - || exit 1
- fi
-
- # Create user if required
- if pw showuser "%%USER%%" 2>/dev/null; then
- echo "---> Using existing user \"%%USER%%\""
- else
- echo "---> Adding user \"%%USER%%\""
- pw adduser %%USER%% -g %%GROUP%% -h - \
- -s "/sbin/nologin" -c "ifGraph User" || exit 1
- fi
-
- ;;
-
POST-INSTALL)
echo "---> Starting post-install script:"