diff options
author | Chris Rees <crees@FreeBSD.org> | 2011-07-10 17:37:11 +0000 |
---|---|---|
committer | Chris Rees <crees@FreeBSD.org> | 2011-07-10 17:37:11 +0000 |
commit | 6d7c5bdddb8b7c4f7f98b59001c4ab77f45b92c4 (patch) | |
tree | f6b841736cd222986f2f1522bac09820c6ce451f /databases/firebird25-server | |
parent | ba98686d6f2e4c7228d26d06068120edc4fc3f6d (diff) |
Notes
Diffstat (limited to 'databases/firebird25-server')
-rw-r--r-- | databases/firebird25-server/Makefile | 5 | ||||
-rw-r--r-- | databases/firebird25-server/files/pkg-install.in | 47 |
2 files changed, 4 insertions, 48 deletions
diff --git a/databases/firebird25-server/Makefile b/databases/firebird25-server/Makefile index e13e0999a9aa..7d478c981965 100644 --- a/databases/firebird25-server/Makefile +++ b/databases/firebird25-server/Makefile @@ -121,8 +121,9 @@ CFLAGS+= -DAMD64 .endif .if !defined(CLIENT_ONLY) -pre-su-install: - @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PORTNAME} PRE-INSTALL + +USERS= ${PORTNAME} +GROUPS= ${USERS} post-install: @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PORTNAME} POST-INSTALL diff --git a/databases/firebird25-server/files/pkg-install.in b/databases/firebird25-server/files/pkg-install.in index c74821080906..b80c710d0b25 100644 --- a/databases/firebird25-server/files/pkg-install.in +++ b/databases/firebird25-server/files/pkg-install.in @@ -1,55 +1,10 @@ #!/bin/sh -# $FreeBSD: /tmp/pcvs/ports/databases/firebird25-server/files/pkg-install.in,v 1.1 2010-12-20 08:48:54 acm Exp $ +# $FreeBSD: /tmp/pcvs/ports/databases/firebird25-server/files/pkg-install.in,v 1.2 2011-07-10 17:37:11 crees Exp $ PATH=/bin:/usr/bin:/usr/sbin case $2 in -PRE-INSTALL) - -if [ `id -u` -ne 0 ]; then - echo; echo "You must be root to run this step!"; echo; echo - exit 1 -fi - -nofbuid=0 -fbUID=`id -u firebird 2>/dev/null` -if [ $? -ne 0 ]; then - fbUID=90 - while [ ! -z `id -un $fbUID 2>/dev/null` ] - do - fbUID=$(($fbUID+1)) - done - nofbuid=1 -fi - -fbGID=`pw groupshow firebird 2>/dev/null` -if [ $? -ne 0 ]; then - fbGID=90 - while [ ! -z `id -gn $fbGID 2>/dev/null` ] - do - fbGID=$(($fbGID+1)) - done - echo "firebird:*:$fbGID:" >> /etc/group -else - fbGID=`echo $fbGID | awk -F: '{print $3}'` -fi - -echo "firebird user using uid $fbUID" -echo "firebird user using gid $fbGID" - -if which -s pw; then - if [ $nofbuid -ne 0 ]; then - pw useradd firebird -u $fbUID -g $fbGID -h - -s /usr/sbin/nologin \ - -d /nonexistent -c "Firebird Database Administrator" - fi -else - echo -n "unable to create user firebird - please create it manually," - echo " before reinstalling this package." - exit 1 -fi -;; - POST-INSTALL) cd /var/db/firebird |