summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonny Davies <woodchip@gentoo.org>2003-07-11 08:05:20 +0000
committerDonny Davies <woodchip@gentoo.org>2003-07-11 08:05:20 +0000
commitd37a9382ebc7637f67e682498e2532340f3aacb5 (patch)
treec02a0471f45f4fbb0fc1456419a0b4e0d2885f73 /net-www
parentclean user/group bits, apachectl (diff)
downloadhistorical-d37a9382ebc7637f67e682498e2532340f3aacb5.tar.gz
historical-d37a9382ebc7637f67e682498e2532340f3aacb5.tar.bz2
historical-d37a9382ebc7637f67e682498e2532340f3aacb5.zip
clean user/group bits, apachectl
Diffstat (limited to 'net-www')
-rw-r--r--net-www/apache/Manifest4
-rw-r--r--net-www/apache/apache-1.3.27-r4.ebuild20
-rw-r--r--net-www/apache/files/apache-1.3.27-apachectl.patch24
3 files changed, 39 insertions, 9 deletions
diff --git a/net-www/apache/Manifest b/net-www/apache/Manifest
index 3c2f47a70ed1..9fc68517b428 100644
--- a/net-www/apache/Manifest
+++ b/net-www/apache/Manifest
@@ -1,6 +1,6 @@
-MD5 6681e79c7ad1ffa642e9d2b9dc35c33e ChangeLog 11886
+MD5 1c8534ee449df4e251cea9a8a4c58456 ChangeLog 11886
MD5 e4c89cfcf1223c75beeacec2e0746c29 apache-1.3.27-r3.ebuild 7684
-MD5 bb24e77f805c84a3c87f9b7c104b1e0b apache-1.3.27-r4.ebuild 8450
+MD5 70351921c425d0b023d03ea9b60bb0f4 apache-1.3.27-r4.ebuild 8452
MD5 91587791c6e5edaec632673b366ecb4f apache-2.0.46.ebuild 10479
MD5 3a77185ae70b22310e8a70b9146aa979 apache-2.0.47.ebuild 10662
MD5 3f87dcb9d5abca78bc68a3825f331087 files/apache-1.3.27_db4_gentoo.patch 812
diff --git a/net-www/apache/apache-1.3.27-r4.ebuild b/net-www/apache/apache-1.3.27-r4.ebuild
index 21127688e7e2..18a777f577e3 100644
--- a/net-www/apache/apache-1.3.27-r4.ebuild
+++ b/net-www/apache/apache-1.3.27-r4.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-www/apache/apache-1.3.27-r4.ebuild,v 1.6 2003/06/22 18:35:46 pauldv Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-www/apache/apache-1.3.27-r4.ebuild,v 1.7 2003/07/11 08:04:44 woodchip Exp $
IUSE="ipv6 pam"
@@ -30,6 +30,9 @@ src_unpack() {
cd ${S} || die
bzip2 -dc ${DISTDIR}/${P}-gentoo.diff.bz2 | patch -p1 || die
+ #Make apachectl read /etc/conf.d/apache
+ patch -p1 <${FILESDIR}/apache-1.3.27-apachectl.patch || die
+
# yet another perl path fix..
cp htdocs/manual/search/manual-index.cgi \
htdocs/manual/search/manual-index.cgi.orig
@@ -70,7 +73,7 @@ src_compile() {
# Allow users to move the default data directory by setting the
# home directory of the 'apache' user elsewhere.
- DATA_DIR=`grep ^apache: /etc/passwd | cut -d: -f6`
+ DATA_DIR=`getent passwd apache | cut -d: -f6`
if [ -z "$DATA_DIR" ]; then
DATA_DIR="/home/httpd"
eerror "DATA_DIR is null! Using default."
@@ -132,14 +135,14 @@ src_compile() {
src_install() {
# Allow users to move the default data directory by setting the
# home directory of the 'apache' user elsewhere.
- DATA_DIR=`grep ^apache: /etc/passwd | cut -d: -f6`
+ DATA_DIR=`getent passwd apache | cut -d: -f6`
if [ -z "$DATA_DIR" ]; then
eerror "DATA_DIR is null! Using defaults."
eerror "You probably want to check /etc/passwd"
DATA_DIR="/home/httpd"
fi
- GID=`grep ^apache: /etc/group |cut -d: -f3`
+ GID=`getent group apache | cut -d: -f3`
if [ -z "${GID}" ]; then
einfo "Using default GID of 81 for Apache"
GID=81
@@ -233,13 +236,16 @@ src_install() {
pkg_postinst() {
# these are in baselayout now; it will not hurt to leave them here though
# moved to pkg_postinst by jnelson, moved to pkg_preinst by lostlogic
- if ! groupmod apache; then
+ getent group apache >/dev/null 2>&1
+ if [ $? -ne 0 ]; then
groupadd -g 81 apache || die "problem adding group apache"
fi
# usermod returns 2 on user-exists-but-no-flags-given
- usermod apache &>/dev/null
- if [ $? != 2 ]; then
+ #usermod apache &>/dev/null
+ #if [ $? != 2 ]; then
+ getent passwd apache >/dev/null 2>&1
+ if [ $? -ne 0 ]; then
useradd -u 81 -g apache -s /bin/false -d /home/httpd -c "apache" apache
assert "problem adding user apache"
fi
diff --git a/net-www/apache/files/apache-1.3.27-apachectl.patch b/net-www/apache/files/apache-1.3.27-apachectl.patch
new file mode 100644
index 000000000000..4ef66c2ba464
--- /dev/null
+++ b/net-www/apache/files/apache-1.3.27-apachectl.patch
@@ -0,0 +1,24 @@
+diff -uNr apache_1.3.27.orig/Makefile.tmpl apache_1.3.27/Makefile.tmpl
+--- apache_1.3.27.orig/Makefile.tmpl 2002-03-13 16:05:27.000000000 -0500
++++ apache_1.3.27/Makefile.tmpl 2003-07-11 03:38:49.000000000 -0400
+@@ -357,7 +357,6 @@
+ fi; \
+ echo "$(INSTALL_SCRIPT) $(TOP)/$(SRC)/support/apachectl[*] $(root)$(sbindir)/$${apachectl}"; \
+ sed -e 's;PIDFILE=.*;PIDFILE=$(runtimedir)/$(TARGET).pid;' \
+- -e 's;HTTPD=.*;HTTPD=$(sbindir)/$(TARGET);' \
+ < $(TOP)/$(SRC)/support/apachectl > $(TOP)/$(SRC)/.apaci.install.tmp && \
+ $(INSTALL_SCRIPT) $(TOP)/$(SRC)/.apaci.install.tmp $(root)$(sbindir)/$${apachectl}; \
+ echo "$(INSTALL_DATA) $(TOP)/$(SRC)/support/apachectl.8 $(root)$(mandir)/man8/$${apachectl}.8"; \
+diff -uNr apache_1.3.27.orig/src/support/apachectl apache_1.3.27/src/support/apachectl
+--- apache_1.3.27.orig/src/support/apachectl 2002-03-13 16:05:37.000000000 -0500
++++ apache_1.3.27/src/support/apachectl 2003-07-11 03:39:26.000000000 -0400
+@@ -25,7 +25,8 @@
+ PIDFILE=/usr/local/apache/logs/httpd.pid
+ #
+ # the path to your httpd binary, including options if necessary
+-HTTPD='/usr/local/apache/src/httpd'
++. /etc/conf.d/apache
++HTTPD="/usr/sbin/apache ${APACHE_OPTS}"
+ #
+ # a command that outputs a formatted text version of the HTML at the
+ # url given on the command line. Designed for lynx, however other