diff options
author | ale <ale@FreeBSD.org> | 2014-03-28 00:09:37 +0800 |
---|---|---|
committer | ale <ale@FreeBSD.org> | 2014-03-28 00:09:37 +0800 |
commit | 175a3f2444f87b998b1645d3ecd4b5cf41800b41 (patch) | |
tree | 6970182b052dcd21d44da9340f0a1e62db6af5fb /lang/php5 | |
parent | 1bab394e6b3d2c0be04c4f895b2973d0d77d6c55 (diff) | |
download | freebsd-ports-gnome-175a3f2444f87b998b1645d3ecd4b5cf41800b41.tar.gz freebsd-ports-gnome-175a3f2444f87b998b1645d3ecd4b5cf41800b41.tar.zst freebsd-ports-gnome-175a3f2444f87b998b1645d3ecd4b5cf41800b41.zip |
Welcome the new mod_php ports, in order to have default packages for
Apache PHP modules.
Submitted by: marcus
Reworked by: ale (me)
Requested by: many, too many
Diffstat (limited to 'lang/php5')
-rw-r--r-- | lang/php5/Makefile | 31 | ||||
-rw-r--r-- | lang/php5/pkg-plist | 3 | ||||
-rw-r--r-- | lang/php5/pkg-plist.mod | 3 |
3 files changed, 21 insertions, 16 deletions
diff --git a/lang/php5/Makefile b/lang/php5/Makefile index 09cac2ced843..70baf14429f1 100644 --- a/lang/php5/Makefile +++ b/lang/php5/Makefile @@ -16,7 +16,7 @@ LICENSE= PHP301 LATEST_LINK= ${PKGNAMEPREFIX}${PORTNAME}${PKGNAMESUFFIX} -USE_BZIP2= yes +USES= tar:bzip2 NO_OPTIONS_SORT=yes .if !defined(PKGNAMESUFFIX) USE_AUTOTOOLS= autoconf @@ -36,15 +36,13 @@ CONFIGURE_ARGS+=--with-layout=GNU \ USE_GNOME= libxml2 -OPTIONS_DEFINE= CLI CGI FPM APACHE AP2FILTER EMBED DEBUG DTRACE IPV6 MAILHEAD LINKTHR ZTS +OPTIONS_DEFINE+=CLI CGI FPM EMBED DEBUG DTRACE IPV6 MAILHEAD LINKTHR ZTS OPTIONS_DEFAULT=CLI CGI FPM IPV6 LINKTHR OPTIONS_SUB= yes CLI_DESC= Build CLI version CGI_DESC= Build CGI version FPM_DESC= Build FPM version -APACHE_DESC= Build Apache module -AP2FILTER_DESC= Use Apache 2.x filter interface (experimental) EMBED_DESC= Build embedded library DEBUG_DESC= Enable debug DTRACE_DESC= Enable DTrace support @@ -53,7 +51,7 @@ MAILHEAD_DESC= Enable mail header patch LINKTHR_DESC= Link thread lib (for threaded extensions) ZTS_DESC= Force Zend Thread Safety (ZTS) build -CONFLICTS= php52-5* php53-5* php55-5* +CONFLICTS= php53-5* php55-5* DESTDIRNAME= INSTALL_ROOT @@ -89,12 +87,10 @@ CONFIGURE_ARGS+=--enable-fpm \ --with-fpm-group=${WWWGRP} .endif -.if ${PORT_OPTIONS:MAPACHE} && ${PORT_OPTIONS:MEMBED} -IGNORE= cannot be built with multiple SAPI (apache and embedded) -.endif - -.if ${PORT_OPTIONS:MAPACHE} -PHP_SAPI+= mod +.if defined(PKGNAMEPREFIX) +USE_PHP= yes +DEFAULT_VERSIONS= php=5 +IGNORE_WITH_PHP=53 55 USE_APACHE= 22+ .include "${PORTSDIR}/Mk/bsd.apache.mk" .if ${PORT_OPTIONS:MAP2FILTER} @@ -102,9 +98,11 @@ CONFIGURE_ARGS+=--with-apxs2filter=${APXS} .else CONFIGURE_ARGS+=--with-apxs2=${APXS} .endif +PLIST= ${PKGDIR}/pkg-plist.mod PKGMESSAGE= ${PKGDIR}/pkg-message.mod -MODULENAME= lib${PORTNAME} -SHORTMODNAME= ${PORTNAME} +MODULENAME= libphp5 +SHORTMODNAME= php5 +WARNING= "!!! If you have a threaded Apache, you must build ${PHP_PORT} with ZTS support to enable thread-safety in extensions !!!" .endif .if ${PORT_OPTIONS:MEMBED} @@ -175,6 +173,7 @@ pre-configure: @${RM} ${WRKSRC}/configure @${CAT} ${WRKSRC}/acinclude.m4 ${WRKSRC}/build/libtool.m4 > ${WRKSRC}/aclocal.m4 +.if !defined(PKGNAMEPREFIX) post-build: @${ECHO_CMD} "PHP_VER=5" > ${WRKDIR}/php.conf @${ECHO_CMD} "PHP_VERSION=${PORTVERSION}" >> ${WRKDIR}/php.conf @@ -187,6 +186,12 @@ test: build post-install: @${INSTALL_DATA} ${WRKSRC}/php.ini-development ${WRKSRC}/php.ini-production \ ${WRKDIR}/php.conf ${STAGEDIR}/${PREFIX}/etc +.else +do-install: + ${MKDIR} ${STAGEDIR}${PREFIX}/${APACHEMODDIR} + ${INSTALL_LIB} ${WRKSRC}/libs/${MODULENAME}.so \ + ${STAGEDIR}${PREFIX}/${APACHEMODDIR} +.endif .else .include "${MASTERDIR}/Makefile.ext" diff --git a/lang/php5/pkg-plist b/lang/php5/pkg-plist index aba12e9c2b83..8700b50c17c4 100644 --- a/lang/php5/pkg-plist +++ b/lang/php5/pkg-plist @@ -235,9 +235,6 @@ lib/php/build/phpize.m4 lib/php/build/run-tests.php lib/php/build/scan_makefile_in.awk lib/php/build/shtool -%%APACHE%%%%APACHEMODDIR%%/%%AP_MODULE%% -%%APACHE%%@exec %D/sbin/apxs -e -a -n %%AP_NAME%% %f -%%APACHE%%@unexec %D/sbin/apxs -e -A -n %%AP_NAME%% %f %%CGI%%man/man1/php-cgi.1.gz man/man1/php-config.1.gz %%CLI%%man/man1/php.1.gz diff --git a/lang/php5/pkg-plist.mod b/lang/php5/pkg-plist.mod new file mode 100644 index 000000000000..a12fa984d65f --- /dev/null +++ b/lang/php5/pkg-plist.mod @@ -0,0 +1,3 @@ +%%APACHEMODDIR%%/%%AP_MODULE%% +@exec %D/sbin/apxs -e -a -n %%AP_NAME%% %f +@unexec %D/sbin/apxs -e -A -n %%AP_NAME%% %f |