diff options
author | ache <ache@FreeBSD.org> | 2001-10-22 01:33:37 +0800 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 2001-10-22 01:33:37 +0800 |
commit | 7ec11e019f9bc1e1f4b0b52035f1f087dd5eb530 (patch) | |
tree | 493f36c09a2347b52dc1a16e06ec89ef0e8c28b0 | |
parent | 4e8ba16eff2ecc02daf855d514e3120659f0e423 (diff) | |
download | freebsd-ports-gnome-7ec11e019f9bc1e1f4b0b52035f1f087dd5eb530.tar.gz freebsd-ports-gnome-7ec11e019f9bc1e1f4b0b52035f1f087dd5eb530.tar.zst freebsd-ports-gnome-7ec11e019f9bc1e1f4b0b52035f1f087dd5eb530.zip |
Switch to www:www
-rw-r--r-- | www/apache13/Makefile | 17 | ||||
-rw-r--r-- | www/apache13/pkg-deinstall | 20 | ||||
-rw-r--r-- | www/apache13/pkg-install | 34 |
3 files changed, 64 insertions, 7 deletions
diff --git a/www/apache13/Makefile b/www/apache13/Makefile index f2f099872871..ef352b6bbdef 100644 --- a/www/apache13/Makefile +++ b/www/apache13/Makefile @@ -7,7 +7,7 @@ PORTNAME= apache PORTVERSION= 1.3.22 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= www MASTER_SITES= http://httpd.apache.org/dist/httpd/ \ ftp://ftp.ccs.neu.edu/net/mirrors/ftp.apache.org/apache/dist/httpd/ \ @@ -31,14 +31,11 @@ DISTNAME= apache_${PORTVERSION} MAINTAINER= ache@freebsd.org -# -# Set APACHE_PERF_TUNING env. variable to YES to get maximum performance -# - HAS_CONFIGURE= yes CONFIGURE_ARGS= \ --prefix=${PREFIX} \ - --server-gid=nogroup \ + --server-uid=www \ + --server-gid=www \ --with-perl=${PERL} \ --with-layout=${FILESDIR}/FreeBSD.layout:FreeBSD \ --suexec-docroot=${PREFIX}/www/data \ @@ -54,7 +51,10 @@ OPTIM= -DHARD_SERVER_LIMIT=512 \ -DDEFAULT_PATH=\\"/bin:/usr/bin:${PREFIX}/bin\\" \ -DACCEPT_FILTER_NAME=\\"httpready\\" -.if defined(APACHE_PERF_TUNING) && ${APACHE_PERF_TUNING} == YES +# +# Set WITH_APACHE_PERF_TUNING env. variable to YES to get maximum performance +# +.if defined(WITH_APACHE_PERF_TUNING) && ${WITH_APACHE_PERF_TUNING} == YES OPTIM+= -DBUFFERED_LOGS CFLAGS+= -O6 -fomit-frame-pointer .endif @@ -64,6 +64,9 @@ CONFIGURE_ENV= OPTIM='${OPTIM}' MAN1= dbmmanage.1 htdigest.1 htpasswd.1 MAN8= ab.8 apachectl.8 apxs.8 httpd.8 logresolve.8 rotatelogs.8 +pre-install: + PKG_PREFIX=${PREFIX} ./pkg-install ${PKGNAME} PRE-INSTALL + post-install: @if [ ! -f ${PREFIX}/etc/rc.d/apache.sh ]; then \ ${ECHO} "Installing ${PREFIX}/etc/rc.d/apache.sh startup file."; \ diff --git a/www/apache13/pkg-deinstall b/www/apache13/pkg-deinstall new file mode 100644 index 000000000000..dc23907bb768 --- /dev/null +++ b/www/apache13/pkg-deinstall @@ -0,0 +1,20 @@ +#!/bin/sh +# $FreeBSD$ +# + +if [ "$2" != "POST-DEINSTALL" ]; then + exit 0 +fi + +USER=www + +if pw usershow "${USER}" 2>/dev/null 1>&2; then + if pw userdel ${USER}; then + echo "Delete user/group \"${USER}\"." + else + echo "Deleting user/group \"${USER}\" failed..." + exit 1 + fi +fi + +exit 0 diff --git a/www/apache13/pkg-install b/www/apache13/pkg-install new file mode 100644 index 000000000000..cbeae9665004 --- /dev/null +++ b/www/apache13/pkg-install @@ -0,0 +1,34 @@ +#!/bin/sh +# $FreeBSD$ +# + +if [ "$2" != "PRE-INSTALL" ]; then + exit 0 +fi + +USER=www +GROUP=${USER} +UID=80 +GID=${UID} + +if ! pw groupshow "${GROUP}" 2>/dev/null 1>&2; then + if pw groupadd ${GROUP} -g ${GID}; then + echo "Added group \"${GROUP}\"." + else + echo "Adding group \"${GROUP}\" failed..." + exit 1 + fi +fi + +if ! pw usershow "${USER}" 2>/dev/null 1>&2; then + if pw useradd ${USER} -u ${UID} -g ${GROUP} -h - \ + -s "/sbin/nologin" -d "/nonexistent" \ + -c "World Wide Web Owner"; \ + then + echo "Added user \"${USER}\"." + else + echo "Adding user \"${USER}\" failed..." + exit 1 + fi +fi +exit 0 |