- stop setting SYSCONFDIR

- put config files in /etc/apache2 instead of /var since this is not
chrooted

- make a couple of comments that refer to 'httpd' refer to 'httpd2'
instead

- don't install the build makefiles

ideas from bernd@ and steven@, ok steven@
This commit is contained in:
deanna 2006-12-25 20:40:02 +00:00
parent 4a36be0139
commit 9e2f1377c6
7 changed files with 87 additions and 71 deletions

View File

@ -1,9 +1,9 @@
# $OpenBSD: Makefile,v 1.6 2006/12/16 00:41:56 deanna Exp $
# $OpenBSD: Makefile,v 1.7 2006/12/25 20:40:02 deanna Exp $
COMMENT= "apache HTTP server"
V= 2.2.3
PKGNAME= apache-httpd-${V}p2
PKGNAME= apache-httpd-${V}p3
DISTNAME= httpd-${V}
CATEGORIES= www net
@ -29,12 +29,14 @@ USE_LIBTOOL= Yes
MASTER_SITES= ${MASTER_SITE_APACHE:=httpd/}
HTTPD_DIR= /var/apache2
SYSCONFDIR= ${HTTPD_DIR}/conf
CONFDIR= ${SYSCONFDIR}/apache2
SUBST_VARS= CONFDIR
CONFIGURE_STYLE= gnu
CONFIGURE_ARGS+= --enable-layout=OpenBSD \
--datadir=${HTTPD_DIR} \
--with-apr=${LOCALBASE} --with-apr-util=${LOCALBASE} \
--with-apr=${LOCALBASE} \
--with-apr-util=${LOCALBASE} \
--enable-ssl --with-ssl=/usr \
--with-mpm=prefork \
--libexecdir=${LOCALBASE}/lib \
@ -48,15 +50,15 @@ FAKE_FLAGS+= rel_user=_apache2 rel_group=_apache2 \
datadir=${PREFIX}/share/examples/apache2 \
sysconfdir=${PREFIX}/share/examples/apache2/conf
_a2sbin=apachectl apxs dbmmanage htdigest htpasswd logresolve rotatelogs
_a2man1= dbmmanage htdigest htpasswd
_a2man8= apachectl apxs httpd logresolve rotatelogs suexec
A2SBIN= apachectl apxs dbmmanage htdigest htpasswd \
logresolve rotatelogs
A2MAN1= dbmmanage htdigest htpasswd
A2MAN8= apachectl apxs httpd logresolve rotatelogs suexec
pre-configure:
@perl -pi -e 's,%%PREFIX%%,${PREFIX},' ${WRKSRC}/config.layout
@perl -pi -e 's,%%CONFDIR%%,${CONFDIR},' ${WRKSRC}/config.layout \
${WRKSRC}/configure
post-install:
chown -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/share
@ -64,15 +66,15 @@ post-install:
chown -R ${BINOWN}:${BINGRP} ${PREFIX}/sbin
chown -R ${LIBOWN}:${LIBGRP} ${PREFIX}/lib
.for i in ${_a2man1}
.for i in ${A2MAN1}
mv ${PREFIX}/man/man1/${i}.1 ${PREFIX}/man/man1/${i}2.1
.endfor
.for i in ${_a2man8}
.for i in ${A2MAN8}
mv ${PREFIX}/man/man8/${i}.8 ${PREFIX}/man/man8/${i}2.8
.endfor
.for i in ${_a2sbin}
.for i in ${A2SBIN}
mv ${PREFIX}/sbin/${i} ${PREFIX}/sbin/${i}2
.endfor

View File

@ -1,7 +1,17 @@
$OpenBSD: patch-Makefile_in,v 1.1.1.1 2006/12/14 07:14:21 deanna Exp $
--- Makefile.in.orig Sun Nov 13 16:33:15 2005
+++ Makefile.in Sun Oct 29 19:50:52 2006
@@ -45,14 +45,18 @@ install-conf:
$OpenBSD: patch-Makefile_in,v 1.2 2006/12/25 20:40:02 deanna Exp $
--- Makefile.in.orig Sun Nov 13 01:33:15 2005
+++ Makefile.in Sun Dec 17 00:42:22 2006
@@ -15,8 +15,7 @@ PROGRAM_DEPENDENCIES = \
PROGRAMS = $(PROGRAM_NAME)
TARGETS = $(PROGRAMS) $(shared_build) $(other_targets)
INSTALL_TARGETS = install-conf install-htdocs install-error install-icons \
- install-other install-cgi install-include install-suexec install-build \
- install-man
+ install-other install-cgi install-include install-suexec install-man
DISTCLEAN_TARGETS = include/ap_config_auto.h include/ap_config_layout.h \
modules.c config.cache config.log config.status build/config_vars.mk \
@@ -45,14 +44,18 @@ install-conf:
( \
n_lm=`awk 'BEGIN {n=0} /@@LoadModule@@/ {n+=1} END {print n}' < $$i`; \
if test $$n_lm -eq 0 -o "x$(DSO_MODULES)" = "x"; then \
@ -22,7 +32,7 @@ $OpenBSD: patch-Makefile_in,v 1.1.1.1 2006/12/14 07:14:21 deanna Exp $
-e 'p' \
< $$i; \
for j in $(DSO_MODULES) "^EOL^"; do \
@@ -62,8 +66,10 @@ install-conf:
@@ -62,8 +65,10 @@ install-conf:
done; \
sed -e '1,/@@LoadModule@@/d' \
-e '/@@LoadModule@@/d' \

View File

@ -1,4 +1,4 @@
$OpenBSD: patch-config_layout,v 1.1.1.1 2006/12/14 07:14:21 deanna Exp $
$OpenBSD: patch-config_layout,v 1.2 2006/12/25 20:40:02 deanna Exp $
--- config.layout.orig Sun Nov 21 13:50:36 2004
+++ config.layout Sun Dec 10 20:33:02 2006
@@ -252,26 +252,26 @@
@ -30,7 +30,7 @@ $OpenBSD: patch-config_layout,v 1.1.1.1 2006/12/14 07:14:21 deanna Exp $
+ libexecdir: ${exec_prefix}/lib
+ mandir: ${exec_prefix}/man
+ datadir: /var/apache2
+ sysconfdir: ${datadir}/conf
+ sysconfdir: %%CONFDIR%%
+ installbuilddir: ${datadir}/build
+ errordir: ${datadir}/error
+ iconsdir: ${datadir}/icons

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-configure,v 1.1 2006/12/25 20:40:02 deanna Exp $
--- configure.orig Sun Dec 17 11:37:04 2006
+++ configure Sun Dec 17 11:41:13 2006
@@ -1975,7 +1975,7 @@ do
ap_last="${ap_cur}"
ap_cur=`eval "echo ${ap_cur}"`
done
-exp_sysconfdir="${ap_cur}"
+exp_sysconfdir=%%CONFDIR%%
APACHE_VAR_SUBST="$APACHE_VAR_SUBST exp_sysconfdir"

View File

@ -0,0 +1,14 @@
$OpenBSD: patch-support_apachectl_in,v 1.1 2006/12/25 20:40:02 deanna Exp $
--- support/apachectl.in.orig Sun Dec 17 11:13:02 2006
+++ support/apachectl.in Sun Dec 17 11:13:38 2006
@@ -82,8 +82,8 @@ start|stop|restart|graceful|graceful-sto
;;
startssl|sslstart|start-SSL)
echo The startssl option is no longer supported.
- echo Please edit httpd.conf to include the SSL configuration settings
- echo and then use "apachectl start".
+ echo Please edit httpd2.conf to include the SSL configuration settings
+ echo and then use "apachectl2 start".
ERROR=2
;;
configtest)

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-support_rotatelogs_c,v 1.1 2006/12/25 20:40:02 deanna Exp $
--- support/rotatelogs.c.orig Sun Dec 17 11:13:52 2006
+++ support/rotatelogs.c Sun Dec 17 11:14:36 2006
@@ -107,7 +107,7 @@ int main (int argc, const char * const a
"or \n\nTransferLog \"|%s /some/where 5M\"\n\n", argv[0]);
#endif
fprintf(stderr,
- "to httpd.conf. The generated name will be /some/where.nnnn "
+ "to httpd2.conf. The generated name will be /some/where.nnnn "
"where nnnn is the\nsystem time at which the log nominally "
"starts (N.B. if using a rotation time,\nthe time will always "
"be a multiple of the rotation time, so you can synchronize\n"

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.4 2006/12/16 00:41:56 deanna Exp $
@comment $OpenBSD: PLIST,v 1.5 2006/12/25 20:40:02 deanna Exp $
@newgroup _apache2:576
@newuser _apache2:576:576:daemon:Apache HTTP Server:/var/empty:/sbin/nologin
include/apache2/
@ -809,26 +809,6 @@ share/doc/apache2/vhosts/name-based.html.ja.euc-jp
share/doc/apache2/vhosts/name-based.html.ko.euc-kr
share/examples/apache2/
@sample /var/apache2/
share/examples/apache2/build/
@sample /var/apache2/build/
share/examples/apache2/build/config.nice
@sample /var/apache2/build/config.nice
share/examples/apache2/build/config_vars.mk
@sample /var/apache2/build/config_vars.mk
share/examples/apache2/build/instdso.sh
@sample /var/apache2/build/instdso.sh
share/examples/apache2/build/library.mk
@sample /var/apache2/build/library.mk
share/examples/apache2/build/ltlib.mk
@sample /var/apache2/build/ltlib.mk
share/examples/apache2/build/mkdir.sh
@sample /var/apache2/build/mkdir.sh
share/examples/apache2/build/program.mk
@sample /var/apache2/build/program.mk
share/examples/apache2/build/rules.mk
@sample /var/apache2/build/rules.mk
share/examples/apache2/build/special.mk
@sample /var/apache2/build/special.mk
share/examples/apache2/cgi-bin/
@sample /var/apache2/cgi-bin/
share/examples/apache2/cgi-bin/printenv
@ -836,65 +816,51 @@ share/examples/apache2/cgi-bin/printenv
share/examples/apache2/cgi-bin/test-cgi
@sample /var/apache2/cgi-bin/test-cgi
share/examples/apache2/conf/
@sample /var/apache2/conf/
@sample ${CONFDIR}/
share/examples/apache2/conf/extra/
@sample /var/apache2/conf/extra/
@sample ${CONFDIR}/extra/
share/examples/apache2/conf/extra/httpd-autoindex.conf
@sample /var/apache2/conf/extra/httpd-autoindex.conf
@sample ${CONFDIR}/extra/httpd-autoindex.conf
share/examples/apache2/conf/extra/httpd-dav.conf
@sample /var/apache2/conf/extra/httpd-dav.conf
@sample ${CONFDIR}/extra/httpd-dav.conf
share/examples/apache2/conf/extra/httpd-default.conf
@sample /var/apache2/conf/extra/httpd-default.conf
@sample ${CONFDIR}/extra/httpd-default.conf
share/examples/apache2/conf/extra/httpd-info.conf
@sample /var/apache2/conf/extra/httpd-info.conf
@sample ${CONFDIR}/extra/httpd-info.conf
share/examples/apache2/conf/extra/httpd-languages.conf
@sample /var/apache2/conf/extra/httpd-languages.conf
@sample ${CONFDIR}/extra/httpd-languages.conf
share/examples/apache2/conf/extra/httpd-manual.conf
@sample /var/apache2/conf/extra/httpd-manual.conf
@sample ${CONFDIR}/extra/httpd-manual.conf
share/examples/apache2/conf/extra/httpd-mpm.conf
@sample /var/apache2/conf/extra/httpd-mpm.conf
@sample ${CONFDIR}/extra/httpd-mpm.conf
share/examples/apache2/conf/extra/httpd-multilang-errordoc.conf
@sample /var/apache2/conf/extra/httpd-multilang-errordoc.conf
@sample ${CONFDIR}/extra/httpd-multilang-errordoc.conf
share/examples/apache2/conf/extra/httpd-ssl.conf
@sample /var/apache2/conf/extra/httpd-ssl.conf
@sample ${CONFDIR}/extra/httpd-ssl.conf
share/examples/apache2/conf/extra/httpd-userdir.conf
@sample /var/apache2/conf/extra/httpd-userdir.conf
@sample ${CONFDIR}/extra/httpd-userdir.conf
share/examples/apache2/conf/extra/httpd-vhosts.conf
@sample /var/apache2/conf/extra/httpd-vhosts.conf
@sample ${CONFDIR}/extra/httpd-vhosts.conf
share/examples/apache2/conf/httpd2.conf
@sample /var/apache2/conf/httpd2.conf
@sample ${CONFDIR}/httpd2.conf
share/examples/apache2/conf/magic
@sample /var/apache2/conf/magic
@sample ${CONFDIR}/magic
share/examples/apache2/conf/mime.types
@sample /var/apache2/conf/mime.types
@sample ${CONFDIR}/mime.types
share/examples/apache2/conf/original/
@sample /var/apache2/conf/original/
share/examples/apache2/conf/original/extra/
@sample /var/apache2/conf/original/extra/
share/examples/apache2/conf/original/extra/httpd-autoindex.conf
@sample /var/apache2/conf/original/extra/httpd-autoindex.conf
share/examples/apache2/conf/original/extra/httpd-dav.conf
@sample /var/apache2/conf/original/extra/httpd-dav.conf
share/examples/apache2/conf/original/extra/httpd-default.conf
@sample /var/apache2/conf/original/extra/httpd-default.conf
share/examples/apache2/conf/original/extra/httpd-info.conf
@sample /var/apache2/conf/original/extra/httpd-info.conf
share/examples/apache2/conf/original/extra/httpd-languages.conf
@sample /var/apache2/conf/original/extra/httpd-languages.conf
share/examples/apache2/conf/original/extra/httpd-manual.conf
@sample /var/apache2/conf/original/extra/httpd-manual.conf
share/examples/apache2/conf/original/extra/httpd-mpm.conf
@sample /var/apache2/conf/original/extra/httpd-mpm.conf
share/examples/apache2/conf/original/extra/httpd-multilang-errordoc.conf
@sample /var/apache2/conf/original/extra/httpd-multilang-errordoc.conf
share/examples/apache2/conf/original/extra/httpd-ssl.conf
@sample /var/apache2/conf/original/extra/httpd-ssl.conf
share/examples/apache2/conf/original/extra/httpd-userdir.conf
@sample /var/apache2/conf/original/extra/httpd-userdir.conf
share/examples/apache2/conf/original/extra/httpd-vhosts.conf
@sample /var/apache2/conf/original/extra/httpd-vhosts.conf
share/examples/apache2/conf/original/httpd.conf
@sample /var/apache2/conf/original/httpd.conf
share/examples/apache2/error/
@sample /var/apache2/error/
share/examples/apache2/error/HTTP_BAD_GATEWAY.html.var