aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorale <ale@FreeBSD.org>2005-03-14 22:41:01 +0800
committerale <ale@FreeBSD.org>2005-03-14 22:41:01 +0800
commitefb9294bc4d6ad42cc1bd1ae49c303e35e0dc18a (patch)
treed4a3d18eb2935d2f27d4c8b2546f0f461037ac6f
parent01fc2b9290bdf632599b0ff0d9a2a883ce9ffce6 (diff)
downloadfreebsd-ports-gnome-efb9294bc4d6ad42cc1bd1ae49c303e35e0dc18a.tar.gz
freebsd-ports-gnome-efb9294bc4d6ad42cc1bd1ae49c303e35e0dc18a.tar.zst
freebsd-ports-gnome-efb9294bc4d6ad42cc1bd1ae49c303e35e0dc18a.zip
Add an option (disabled by default) to build the openssl extension statically.
Requested by: too many people
-rw-r--r--lang/php4/Makefile13
1 files changed, 12 insertions, 1 deletions
diff --git a/lang/php4/Makefile b/lang/php4/Makefile
index 83aff60e01e9..e54469434044 100644
--- a/lang/php4/Makefile
+++ b/lang/php4/Makefile
@@ -71,7 +71,8 @@ OPTIONS= REDIRECT "Enable force-cgi-redirect support" off \
OPTIONS= APACHE2 "Use apache 2.x instead of apache 1.3.x" off
.endif
OPTIONS+= DEBUG "Enable debug" off \
- IPV6 "Enable ipv6 support" on
+ IPV6 "Enable ipv6 support" on \
+ OPENSSL "Build static OpenSSL extension" off
EXT_DIR= 20020429
@@ -109,6 +110,13 @@ SAPI_FILE= bin/php
CONFIGURE_ENV= ac_cv_pthreads_lib=${PTHREAD_LIBS} \
ac_cv_pthreads_cflags=${PTHREAD_CFLAGS}
+.if defined(WITH_OPENSSL)
+.include "${PORTSDIR}/Mk/bsd.openssl.mk"
+CONFIGURE_ARGS+=--with-openssl=${OPENSSLBASE} \
+ --with-openssl-dir=${OPENSSLBASE}
+LDFLAGS+= -L${OPENSSLLIB} -lcrypto -lssl
+.endif
+
.if defined(WITH_APACHE)
.if exists(${LOCALBASE}/include/apache2/httpd.h)
WITH_APACHE2= yes
@@ -182,6 +190,9 @@ post-build:
@${ECHO_CMD} "PHP_EXT_DIR=${EXT_DIR}" >> ${WRKDIR}/php.conf
@${ECHO_CMD} "PHP_PORT=\$${PORTSDIR}/${PHP_PORT}" >> ${WRKDIR}/php.conf
@${ECHO_CMD} "PHP_SAPI=${PHP_SAPI}" >> ${WRKDIR}/php.conf
+.if defined(WITH_OPENSSL)
+ @${ECHO_CMD} "PHP_EXT_INC=openssl" >> ${WRKDIR}/php.conf
+.endif
post-install:
@${INSTALL_DATA} ${WRKSRC}/php.ini-dist ${PREFIX}/etc