summaryrefslogtreecommitdiffstats
path: root/www
diff options
context:
space:
mode:
authordirk <dirk@FreeBSD.org>2002-11-21 20:37:21 +0000
committerdirk <dirk@FreeBSD.org>2002-11-21 20:37:21 +0000
commitfbff5b03cd7c9ca4c1135a2e0e970c2f228f3bd3 (patch)
tree6f04951ea606d75d7ba8fe134a736f465f0ee01a /www
parent837a2114d7a89a76342fd55f3383577937e457bb (diff)
downloadFreeBSD-ports-fbff5b03cd7c9ca4c1135a2e0e970c2f228f3bd3.zip
FreeBSD-ports-fbff5b03cd7c9ca4c1135a2e0e970c2f228f3bd3.tar.gz
Try to autodetect if apache2 is installed. Build as an apache2 module
if so.
Diffstat (limited to 'www')
-rw-r--r--www/mod_php4/Makefile15
-rw-r--r--www/mod_php5/Makefile15
2 files changed, 26 insertions, 4 deletions
diff --git a/www/mod_php4/Makefile b/www/mod_php4/Makefile
index 27264d9..4eede4b 100644
--- a/www/mod_php4/Makefile
+++ b/www/mod_php4/Makefile
@@ -37,6 +37,12 @@ SLAVEDIRS= lang/php4
USE_BZIP2= yes
USE_SUBMAKE= yes
USE_AUTOCONF_VER=213
+
+.include <bsd.port.pre.mk>
+.if exists(${LOCALBASE}/include/apache2/apr.h)
+WITH_APACHE2= yes
+.endif
+
.if defined(WITH_APACHE2)
APACHE_PORT?= ${PORTSDIR}/www/apache2
.else
@@ -85,9 +91,14 @@ SCRIPTS_ENV= WRKDIRPREFIX="${WRKDIRPREFIX}" \
pre-fetch:
@${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/configure.php
-.if !defined(STANDALONE) && !defined(WITH_APACHE2)
+.if !defined(STANDALONE)
+.if !defined(WITH_APACHE2)
@${ECHO_CMD} "Define WITH_APACHE2 to build mod_php4 as an apache2 module."
@${ECHO_CMD} ""
+.else
+ @${ECHO_CMD} "Building mod_php4 as an apache2 module."
+ @${ECHO_CMD} ""
+.endif
.endif
post-install:
@@ -120,4 +131,4 @@ post-clean:
.include "${WRKDIRPREFIX}${.CURDIR}/Makefile.inc"
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/www/mod_php5/Makefile b/www/mod_php5/Makefile
index 27264d9..4eede4b 100644
--- a/www/mod_php5/Makefile
+++ b/www/mod_php5/Makefile
@@ -37,6 +37,12 @@ SLAVEDIRS= lang/php4
USE_BZIP2= yes
USE_SUBMAKE= yes
USE_AUTOCONF_VER=213
+
+.include <bsd.port.pre.mk>
+.if exists(${LOCALBASE}/include/apache2/apr.h)
+WITH_APACHE2= yes
+.endif
+
.if defined(WITH_APACHE2)
APACHE_PORT?= ${PORTSDIR}/www/apache2
.else
@@ -85,9 +91,14 @@ SCRIPTS_ENV= WRKDIRPREFIX="${WRKDIRPREFIX}" \
pre-fetch:
@${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/configure.php
-.if !defined(STANDALONE) && !defined(WITH_APACHE2)
+.if !defined(STANDALONE)
+.if !defined(WITH_APACHE2)
@${ECHO_CMD} "Define WITH_APACHE2 to build mod_php4 as an apache2 module."
@${ECHO_CMD} ""
+.else
+ @${ECHO_CMD} "Building mod_php4 as an apache2 module."
+ @${ECHO_CMD} ""
+.endif
.endif
post-install:
@@ -120,4 +131,4 @@ post-clean:
.include "${WRKDIRPREFIX}${.CURDIR}/Makefile.inc"
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
OpenPOWER on IntegriCloud