1998-07-25 07:30:31 -04:00
|
|
|
# New ports collection makefile for: apache HTTPD / php3
|
1998-11-06 06:02:22 -05:00
|
|
|
# Version required: 1.3* / 3.0*
|
1998-07-25 07:30:31 -04:00
|
|
|
# Date created: So 21 Jun 1998 16:09:39 CEST
|
|
|
|
# Whom: Stefan Herrmann <stefan@asterix.webaffairs.net>
|
1995-08-28 09:28:45 -04:00
|
|
|
#
|
1998-12-22 19:44:50 -05:00
|
|
|
# $Id: Makefile,v 1.58 1998/12/02 20:32:02 billf Exp $
|
1995-08-28 09:28:45 -04:00
|
|
|
#
|
|
|
|
|
1998-09-30 14:16:08 -04:00
|
|
|
DISTNAME= apache_${VERSION_APACHE}
|
|
|
|
PKGNAME= apache-php${VERSION_PHP3}-${VERSION_APACHE}
|
1996-11-18 06:44:27 -05:00
|
|
|
CATEGORIES= www
|
1998-06-14 05:58:22 -04:00
|
|
|
MASTER_SITES= ftp://www.apache.org/apache/dist/ \
|
1998-12-05 04:36:59 -05:00
|
|
|
http://www.rge.com/pub/infosystems/apache/dist/ \
|
|
|
|
http://www.apache.de/dist/ \
|
|
|
|
http://www.php.net/distributions/ \
|
|
|
|
ftp://www.php.net/pub/distributions/ \
|
|
|
|
http://php.he.net/distributions/ \
|
|
|
|
http://www.php3.de/distributions/
|
1998-09-30 14:16:08 -04:00
|
|
|
DISTFILES= apache_${VERSION_APACHE}.tar.gz php-${VERSION_PHP3}.tar.gz
|
1995-08-28 09:28:45 -04:00
|
|
|
|
1998-12-22 19:44:50 -05:00
|
|
|
MAINTAINER= dirk@FreeBSD.ORG
|
1997-09-03 14:45:16 -04:00
|
|
|
|
1998-11-06 06:02:22 -05:00
|
|
|
VERSION_APACHE= 1.3.3
|
|
|
|
VERSION_PHP3= 3.0.5
|
1998-09-01 14:38:05 -04:00
|
|
|
|
1998-07-25 07:30:31 -04:00
|
|
|
#
|
|
|
|
# Set APACHE_PERF_TUNING env. variable to YES to get maximum performance
|
|
|
|
#
|
|
|
|
|
|
|
|
GNU_CONFIGURE= yes
|
|
|
|
CONFIGURE_ARGS= \
|
|
|
|
--sysconfdir=${PREFIX}/etc/apache \
|
|
|
|
--includedir=${PREFIX}/include/apache \
|
|
|
|
--logfiledir=/var/log \
|
|
|
|
--runtimedir=/var/run \
|
|
|
|
--datadir=${PREFIX}/www \
|
|
|
|
--proxycachedir=${PREFIX}/www/proxy \
|
|
|
|
--libexecdir=${PREFIX}/libexec/apache \
|
1998-09-30 14:16:08 -04:00
|
|
|
--without-confadjust \
|
1998-07-25 07:30:31 -04:00
|
|
|
--enable-shared=remain \
|
|
|
|
--enable-module=most \
|
|
|
|
--enable-module=auth_db \
|
|
|
|
--disable-module=auth_dbm \
|
|
|
|
--activate-module=src/modules/php3/libphp3.a
|
1998-06-14 05:58:22 -04:00
|
|
|
|
1998-09-30 14:16:08 -04:00
|
|
|
# Currently perl version don't matter
|
|
|
|
# --with-perl=${PERL5}
|
|
|
|
|
1998-07-25 07:30:31 -04:00
|
|
|
OPTIM=-DHARD_SERVER_LIMIT=512 \
|
|
|
|
-DDOCUMENT_LOCATION=\\"${PREFIX}/www/data/\\" \
|
|
|
|
-DDEFAULT_PATH=\\"/bin:/usr/bin:${PREFIX}/bin\\"
|
|
|
|
|
|
|
|
.if defined(APACHE_PERF_TUNING) && ${APACHE_PERF_TUNING} == YES
|
|
|
|
OPTIM+= -DBUFFERED_LOGS
|
1998-09-30 14:16:08 -04:00
|
|
|
CFLAGS+= -O6 -fomit-frame-pointer
|
1998-02-22 18:06:17 -05:00
|
|
|
.endif
|
|
|
|
|
1998-09-01 14:38:05 -04:00
|
|
|
CONFIGURE_ENV= OPTIM='${OPTIM}' LIBS='-L${PREFIX}/lib'
|
1998-07-25 07:30:31 -04:00
|
|
|
|
|
|
|
MAN1= ab.1 apachectl.1 dbmmanage.1 htdigest.1 htpasswd.1
|
|
|
|
MAN8= apxs.8 httpd.8 logresolve.8 rotatelogs.8
|
1998-06-14 05:58:22 -04:00
|
|
|
|
1998-07-25 07:30:31 -04:00
|
|
|
APACHEDOCDIR= ${PREFIX}/share/doc/apache
|
|
|
|
PHP3DOCDIR= ${PREFIX}/share/doc/php3
|
1998-07-25 02:51:26 -04:00
|
|
|
|
1998-07-25 07:30:31 -04:00
|
|
|
PHP3_CONF_ARGS= --prefix=${PREFIX} \
|
|
|
|
--with-system-regex \
|
|
|
|
--with-apache=${WRKSRC} \
|
|
|
|
--with-config-file-path=${PREFIX}/lib \
|
1998-09-30 14:16:08 -04:00
|
|
|
--disable-debug \
|
|
|
|
--enable-track-vars
|
1998-06-14 05:58:22 -04:00
|
|
|
|
1998-09-30 14:16:08 -04:00
|
|
|
pre-fetch:
|
1998-12-22 19:44:50 -05:00
|
|
|
.if !defined(BATCH)
|
1998-09-01 14:38:05 -04:00
|
|
|
@${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/configure.php
|
1998-12-22 19:44:50 -05:00
|
|
|
.endif
|
1996-05-20 03:37:06 -04:00
|
|
|
|
1997-09-03 14:45:16 -04:00
|
|
|
pre-configure:
|
1998-09-30 14:16:08 -04:00
|
|
|
@cd ${WRKSRC} \
|
1998-09-01 14:38:05 -04:00
|
|
|
&& ./configure > /dev/null \
|
1998-09-30 14:16:08 -04:00
|
|
|
&& cd ${WRKDIR}/php-${VERSION_PHP3} \
|
|
|
|
&& ${ECHO_MSG} "===> Configuring for PHP-${VERSION_PHP3}" \
|
1998-12-22 19:44:50 -05:00
|
|
|
&& CC="${CC}" \
|
|
|
|
ac_cv_path_CC="${CC}" \
|
|
|
|
CFLAGS="${CFLAGS}" \
|
|
|
|
CPPFLAGS="-I${PREFIX}/include -I${PREFIX}/include/gd" \
|
|
|
|
LDFLAGS=-L${PREFIX}/lib \
|
|
|
|
./configure ${PHP3_CONF_ARGS} \
|
1998-09-30 14:16:08 -04:00
|
|
|
&& ${ECHO_MSG} "===> Building for PHP-${VERSION_PHP3}" \
|
1998-07-25 07:30:31 -04:00
|
|
|
&& ${MAKE} install \
|
1998-09-30 14:16:08 -04:00
|
|
|
&& ${ECHO_MSG} "===> Configuring for Apache-${VERSION_APACHE}"
|
1997-09-03 14:45:16 -04:00
|
|
|
|
1996-06-15 12:58:09 -04:00
|
|
|
post-install:
|
1998-06-14 05:58:22 -04:00
|
|
|
@if [ ! -f ${PREFIX}/etc/rc.d/apache.sh ]; then \
|
1997-10-04 10:53:11 -04:00
|
|
|
${ECHO} "Installing ${PREFIX}/etc/rc.d/apache.sh startup file."; \
|
1998-07-25 07:30:31 -04:00
|
|
|
${ECHO} "#!/bin/sh" > ${PREFIX}/etc/rc.d/apache.sh; \
|
1998-08-27 10:08:20 -04:00
|
|
|
${ECHO} "[ -d ${PREFIX}/pgsql/lib ] && ${LDCONFIG} -m ${PREFIX}/pgsql/lib" >> ${PREFIX}/etc/rc.d/apache.sh; \
|
1998-09-30 14:16:08 -04:00
|
|
|
${ECHO} "[ -x ${PREFIX}/sbin/apachectl ] && ${PREFIX}/sbin/apachectl start${SSL} > /dev/null && ${ECHO} -n ' apache'" >> ${PREFIX}/etc/rc.d/apache.sh; \
|
1996-06-15 13:51:08 -04:00
|
|
|
chmod 751 ${PREFIX}/etc/rc.d/apache.sh; \
|
|
|
|
fi
|
1998-09-30 14:16:08 -04:00
|
|
|
${INSTALL_DATA} ${WRKDIR}/php-${VERSION_PHP3}/php3.ini-dist ${PREFIX}/lib
|
|
|
|
.for i in php2 php3 phpi phps
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/php-${VERSION_PHP3}/extra/icons/$i.gif ${PREFIX}/www/icons
|
|
|
|
.endfor
|
1998-07-25 07:30:31 -04:00
|
|
|
|
1998-06-14 05:58:22 -04:00
|
|
|
.if !defined(NOPORTDOCS)
|
1998-07-25 07:30:31 -04:00
|
|
|
${MKDIR} ${APACHEDOCDIR} ${PHP3DOCDIR}
|
1998-06-14 05:58:22 -04:00
|
|
|
.for i in README LICENSE ABOUT_APACHE
|
1998-07-25 07:30:31 -04:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/$i ${APACHEDOCDIR}
|
|
|
|
.endfor
|
|
|
|
(cd ${WRKSRC}/htdocs && tar cf - *) |\
|
|
|
|
(cd ${APACHEDOCDIR} && tar xf -); \
|
|
|
|
find ${APACHEDOCDIR} -type d -exec chmod a+rx {} \; ; \
|
|
|
|
find ${APACHEDOCDIR} -type f -exec chmod a+r {} \;
|
|
|
|
.for i in apache_pb.gif index.html manual
|
1998-09-01 14:38:05 -04:00
|
|
|
${LN} -s ${PREFIX}/share/doc/apache/$i ${PREFIX}/www/data/$i
|
1998-07-25 07:30:31 -04:00
|
|
|
.endfor
|
|
|
|
.for i in CODING_STANDARDS EXTENSION_STATUS LICENSE
|
1998-09-30 14:16:08 -04:00
|
|
|
${INSTALL_DATA} ${WRKDIR}/php-${VERSION_PHP3}/$i ${PHP3DOCDIR}
|
1998-06-14 05:58:22 -04:00
|
|
|
.endfor
|
1998-09-01 14:38:05 -04:00
|
|
|
@${ECHO} "Docs reside in ${APACHEDOCDIR}"
|
|
|
|
@${ECHO} "and in ${PHP3DOCDIR}"
|
1998-06-14 05:58:22 -04:00
|
|
|
.endif
|
1996-06-15 12:58:09 -04:00
|
|
|
|
1998-09-01 14:38:05 -04:00
|
|
|
# This was copied from bsd.port.mk because a missing post-clean target
|
|
|
|
# is needed
|
|
|
|
clean:
|
|
|
|
.if !defined(NOCLEANDEPENDS)
|
|
|
|
@${MAKE} clean-depends
|
|
|
|
.endif
|
|
|
|
@${ECHO_MSG} "===> Cleaning for ${PKGNAME}"
|
|
|
|
@if [ -d ${WRKDIR} ]; then \
|
|
|
|
if [ -w ${WRKDIR} ]; then \
|
|
|
|
${RM} -rf ${WRKDIR}; \
|
|
|
|
else \
|
|
|
|
${ECHO_MSG} "===> ${WRKDIR} not writable, skipping"; \
|
|
|
|
fi; \
|
|
|
|
fi
|
1998-12-22 19:44:50 -05:00
|
|
|
@${RM} -f ${WRKDIRPREFIX}${.CURDIR}/Makefile.inc
|
1998-09-01 14:38:05 -04:00
|
|
|
|
1998-12-22 19:44:50 -05:00
|
|
|
.if exists(${WRKDIRPREFIX}${.CURDIR}/Makefile.inc)
|
|
|
|
.include "${WRKDIRPREFIX}${.CURDIR}/Makefile.inc"
|
1998-09-01 14:38:05 -04:00
|
|
|
.endif
|
1995-08-28 09:28:45 -04:00
|
|
|
.include <bsd.port.mk>
|