FreeBSD Bugzilla – Attachment 171947 Details for
Bug 210697
Remove etc/php/extension.ini
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch
php-ter.diff (text/plain), 12.85 KB, created by
Mathieu Arnold
on 2016-06-29 15:08:44 UTC
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Mathieu Arnold
Created:
2016-06-29 15:08:44 UTC
Size:
12.85 KB
patch
obsolete
>diff --git Mk/Scripts/create-manifest.sh Mk/Scripts/create-manifest.sh >index a960505..f543523 100644 >--- Mk/Scripts/create-manifest.sh >+++ Mk/Scripts/create-manifest.sh >@@ -104,7 +104,9 @@ done > > exec >${dp_METADIR}/+DISPLAY > >-[ -f ${dp_PKGMESSAGE} ] && cat ${dp_PKGMESSAGE} >+for message in ${dp_PKGMESSAGE}; do >+ [ -f "${message}" ] && cat "${message}" >+done > > # Try and keep these messages in sync with check-deprecated > if [ ${dp_MAINTAINER} = "ports@FreeBSD.org" ]; then >diff --git Mk/Uses/php.mk Mk/Uses/php.mk >index 32b4505..5db089f 100644 >--- Mk/Uses/php.mk >+++ Mk/Uses/php.mk >@@ -204,7 +204,20 @@ _INCLUDE_USES_PHP_POST_MK=yes > > . if ${php_ARGS:Mext} || ${php_ARGS:Mzend} > PHP_MODNAME?= ${PORTNAME} >+PHP_EXT_PKGMESSAGE= ${WRKDIR}/php-ext-pkg-message >+PKGMESSAGE+= ${PHP_EXT_PKGMESSAGE} > PHP_HEADER_DIRS?= "" >+# If there is no priority defined, we wing it. >+. if !defined(PHP_MOD_PRIO) >+. if defined(USE_PHP) >+# If an extension needs another, put it after the others. >+PHP_MOD_PRIO= 30 >+. else >+# Otherwise, put it where it with everybody. >+PHP_MOD_PRIO= 20 >+. endif >+. endif >+INI_FILE= etc/php/ext-${PHP_MOD_PRIO}-${PHP_MODNAME}.ini > > do-install: > @${MKDIR} ${STAGEDIR}${PREFIX}/lib/php/${PHP_EXT_DIR} >@@ -219,8 +232,13 @@ do-install: > @${GREP} "#define \(COMPILE\|HAVE\|USE\)_" ${WRKSRC}/config.h \ > > ${STAGEDIR}${PREFIX}/include/php/ext/${PHP_MODNAME}/config.h > @${MKDIR} ${STAGEDIR}${PREFIX}/etc/php >+. if ${php_ARGS:Mzend} >+ @${ECHO_CMD} "zend_extension=%D/lib/php/${PHP_EXT_DIR}/${PHP_MODNAME}.so" > ${STAGEDIR}${PREFIX}/${INI_FILE} >+. else >+ @${ECHO_CMD} "extension=${PHP_MODNAME}.so" > ${STAGEDIR}${PREFIX}/${INI_FILE} >+. endif > >-add-plist-info: add-plist-phpext >+_USES_stage+= 899:add-plist-phpext > add-plist-phpext: > @${ECHO_CMD} "lib/php/${PHP_EXT_DIR}/${PHP_MODNAME}.so" \ > >> ${TMPPLIST} >@@ -234,44 +252,20 @@ add-plist-phpext: > >> ${TMPPLIST} > @${ECHO_CMD} "@unexec rm %D/include/php/ext/php_config.h.orig" \ > >> ${TMPPLIST} >- @${ECHO_CMD} "@dir etc/php" \ >+ @${ECHO_CMD} "${INI_FILE}" \ > >> ${TMPPLIST} >+ @${ECHO_CMD} "****************************************************************************" > ${PHP_EXT_PKGMESSAGE} >+ @${ECHO_CMD} "" >> ${PHP_EXT_PKGMESSAGE} >+ @${ECHO_CMD} "The following line has been added to your ${PREFIX}/${INI_FILE}" >> ${PHP_EXT_PKGMESSAGE} >+ @${ECHO_CMD} "configuration file to automatically load the installed extension:" >> ${PHP_EXT_PKGMESSAGE} >+ @${ECHO_CMD} "" >> ${PHP_EXT_PKGMESSAGE} > . if ${php_ARGS:Mzend} >- @${ECHO_CMD} "@exec echo zend_extension=%D/lib/php/${PHP_EXT_DIR}/${PHP_MODNAME}.so >> %D/etc/php/extensions.ini" \ >- >> ${TMPPLIST} >-. else >- @${ECHO_CMD} "@exec echo extension=${PHP_MODNAME}.so >> %D/etc/php/extensions.ini" \ >- >> ${TMPPLIST} >-. endif >- @${ECHO_CMD} "@unexec cp %D/etc/php/extensions.ini %D/etc/php/extensions.ini.orig" \ >- >> ${TMPPLIST} >-. if ${php_ARGS:Mzend} >- @${ECHO_CMD} "@unexec grep -v zend_extension=%D/lib/php/${PHP_EXT_DIR}/${PHP_MODNAME}\\\.so %D/etc/php/extensions.ini.orig > %D/etc/php/extensions.ini || true" \ >- >> ${TMPPLIST} >-. else >- @${ECHO_CMD} "@unexec grep -v extension=${PHP_MODNAME}\\\.so %D/etc/php/extensions.ini.orig > %D/etc/php/extensions.ini || true" \ >- >> ${TMPPLIST} >-. endif >- @${ECHO_CMD} "@unexec rm %D/etc/php/extensions.ini.orig" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@unexec [ -s %D/etc/php/extensions.ini ] || rm %D/etc/php/extensions.ini" \ >- >> ${TMPPLIST} >- >-package-message: php-ini >- >-php-ini: >- @${ECHO_CMD} "****************************************************************************" >- @${ECHO_CMD} "" >- @${ECHO_CMD} "The following line has been added to your ${PREFIX}/etc/php/extensions.ini" >- @${ECHO_CMD} "configuration file to automatically load the installed extension:" >- @${ECHO_CMD} "" >-. if ${php_ARGS:Mzend} >- @${ECHO_CMD} "zend_extension=${PREFIX}/lib/php/${PHP_EXT_DIR}/${PHP_MODNAME}.so" >+ @${ECHO_CMD} "zend_extension=${PREFIX}/lib/php/${PHP_EXT_DIR}/${PHP_MODNAME}.so" >> ${PHP_EXT_PKGMESSAGE} > . else >- @${ECHO_CMD} "extension=${PHP_MODNAME}.so" >+ @${ECHO_CMD} "extension=${PHP_MODNAME}.so" >> ${PHP_EXT_PKGMESSAGE} > . endif >- @${ECHO_CMD} "" >- @${ECHO_CMD} "****************************************************************************" >+ @${ECHO_CMD} "" >> ${PHP_EXT_PKGMESSAGE} >+ @${ECHO_CMD} "****************************************************************************" >> ${PHP_EXT_PKGMESSAGE} > . endif > > # Extensions >diff --git databases/php-adodb-ext/Makefile databases/php-adodb-ext/Makefile >index f39940a..46c4e65 100644 >--- databases/php-adodb-ext/Makefile >+++ databases/php-adodb-ext/Makefile >@@ -16,8 +16,7 @@ WRKSRC= ${WRKDIR}/adodb-${PORTVERSION:S/.//} > > USES= dos2unix php:ext zip > IGNORE_WITH_PHP=56 70 >- >-SUB_FILES= pkg-message >+PHP_MODNAME= adodb > > .include <bsd.port.pre.mk> > >diff --git databases/php-adodb-ext/files/pkg-message.in databases/php-adodb-ext/files/pkg-message.in >deleted file mode 100644 >index 2703f9f..0000000 >--- databases/php-adodb-ext/files/pkg-message.in >+++ /dev/null >@@ -1,13 +0,0 @@ >-***************************************************************************** >-The ADOdb extension has been installed successful. >-Add a line containing >- >- extension=adodb.so >- >-to your %%LOCALBASE%%/etc/php/extensions.ini to load it. >-If you have the Zend Optimizer installed, add the line >- >- zend_extension=%%PREFIX%%/lib/php/%%PHP_EXT_DIR%%/adodb.so >- >-to your [zend] section in the php.ini file, too. >-***************************************************************************** >diff --git devel/ioncube/Makefile devel/ioncube/Makefile >index 175e4b2..d55953a 100644 >--- devel/ioncube/Makefile >+++ devel/ioncube/Makefile >@@ -31,5 +31,10 @@ do-install: > ${STAGEDIR}${PREFIX}/lib/php/${PHP_EXT_DIR}/ioncube/ioncube_loader.so > ${INSTALL_DATA} ${WRKSRC}/ioncube_loader_fre_${PHP_INSTVER}_ts.so \ > ${STAGEDIR}${PREFIX}/lib/php/${PHP_EXT_DIR}/ioncube/ioncube_loader_ts.so >+# Put it before opcache, like the previous pkg-message was saying >+ @${MKDIR} ${STAGEDIR}${PREFIX}/etc/php >+ @${ECHO_CMD} "[Zend]" > ${STAGEDIR}${PREFIX}/etc/php/ext-05-ioncube.ini >+ @${ECHO_CMD} "zend_extension=${PREFIX}/lib/php/${PHP_EXT_DIR}/ioncube/ioncube_loader.so" >> ${STAGEDIR}${PREFIX}/etc/php/ext-05-ioncube.ini >+ @${ECHO_CMD} "zend_extension_ts=${PREFIX}/lib/php/${PHP_EXT_DIR}/ioncube/ioncube_loader_ts.so" >> ${STAGEDIR}${PREFIX}/etc/php/ext-05-ioncube.ini > > .include <bsd.port.mk> >diff --git devel/ioncube/files/pkg-message.in devel/ioncube/files/pkg-message.in >index 5bb7f4f..d431bfd 100644 >--- devel/ioncube/files/pkg-message.in >+++ devel/ioncube/files/pkg-message.in >@@ -1,14 +1,8 @@ >- > You have installed the ionCube loader package. > >-Edit %%LOCALBASE%%/etc/php.ini or %%LOCALBASE%%/etc/php/extensions.ini >-and add this three lines: >+The following lines have been added to %%PREFIX%%/etc/php/ext-05-ioncube.ini so >+that the extension has been automatically activated. > >--------------------------------------------------------------------------------- > [Zend] >-zend_extension="%%PREFIX%%/lib/php/%%PHP_EXT_DIR%%/ioncube/ioncube_loader.so" >-zend_extension_ts="%%PREFIX%%/lib/php/%%PHP_EXT_DIR%%/ioncube/ioncube_loader_ts.so" >--------------------------------------------------------------------------------- >- >-NOTE: If you have any Zend Extension already installed - you need put this before >-existing zend_extension lines. >+zend_extension=%%PREFIX%%/lib/php/%%PHP_EXT_DIR%%/ioncube/ioncube_loader.so >+zend_extension_ts=%%PREFIX%%/lib/php/%%PHP_EXT_DIR%%/ioncube/ioncube_loader_ts.so >diff --git devel/ioncube/pkg-plist devel/ioncube/pkg-plist >index 98591e1..188863c 100644 >--- devel/ioncube/pkg-plist >+++ devel/ioncube/pkg-plist >@@ -1,2 +1,3 @@ >+etc/php/ext-05-ioncube.ini > lib/php/%%PHP_EXT_DIR%%/ioncube/ioncube_loader.so > lib/php/%%PHP_EXT_DIR%%/ioncube/ioncube_loader_ts.so >diff --git devel/php5-ice/Makefile devel/php5-ice/Makefile >index 77640f0..9b4eacb 100644 >--- devel/php5-ice/Makefile >+++ devel/php5-ice/Makefile >@@ -34,27 +34,12 @@ PHP_MODNAME?= IcePHP > post-install: > ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/php/${PHP_EXT_DIR}/*.so > @${MKDIR} ${STAGEDIR}${PREFIX}/etc/php >- >-add-plist-info: >- @${ECHO_CMD} "@exec mkdir -p %D/etc/php" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@exec echo extension=${PHP_MODNAME}.so >> %D/etc/php/extensions.ini" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@unexec cp %D/etc/php/extensions.ini %D/etc/php/extensions.ini.orig" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@unexec grep -v extension=${PHP_MODNAME}\\\.so %D/etc/php/extensions.ini.orig > %D/etc/php/extensions.ini || true" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@unexec rm %D/etc/php/extensions.ini.orig" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@unexec [ -s %D/etc/php/extensions.ini ] || rm %D/etc/php/extensions.ini" \ >- >> ${TMPPLIST} >- @${ECHO_CMD} "@unexec rmdir %D/etc/php 2> /dev/null || true" \ >- >> ${TMPPLIST} >+ @${ECHO_CMD} "extension=${PHP_MODNAME}.so" > ${STAGEDIR}${PREFIX}/etc/php/ext-20-ice.ini > > security-check: > @${ECHO_CMD} "****************************************************************************" > @${ECHO_CMD} "" >- @${ECHO_CMD} "The following line has been added to your ${PREFIX}/etc/php/extensions.ini" >+ @${ECHO_CMD} "The following line has been added to your ${PREFIX}/etc/php/ext-20-ice.ini" > @${ECHO_CMD} "configuration file to automatically load the installed extension:" > @${ECHO_CMD} "" > @${ECHO_CMD} "extension=${PHP_MODNAME}.so" >diff --git devel/php5-ice/pkg-plist devel/php5-ice/pkg-plist >index 570fe99..58f023e 100644 >--- devel/php5-ice/pkg-plist >+++ devel/php5-ice/pkg-plist >@@ -1,3 +1,4 @@ >+etc/php/ext-20-ice.ini > lib/php/%%PHP_EXT_DIR%%/IcePHP.so > share/pear/Glacier2.php > share/pear/Glacier2/Metrics.php >diff --git graphics/mapserver/Makefile graphics/mapserver/Makefile >index 02cbe9d..601a82f 100644 >--- graphics/mapserver/Makefile >+++ graphics/mapserver/Makefile >@@ -125,11 +125,9 @@ CMAKE_ARGS+= -DWITH_POSTGIS=0 > .endif > > .if ${PORT_OPTIONS:MPHP} >-BUILD_DEPENDS+= ${LOCALBASE}/bin/php-config:lang/php56 >-RUN_BUILDS+= ${LOCALBASE}/bin/php-config:lang/php56 >-PHP_EXTENSION_DIR!= ${LOCALBASE}/bin/php-config --extension-dir | ${SED} -e "s,/usr/local/,," >+USES+= php:build >+IGNORE_WITH_PHP= 55 70 > CMAKE_ARGS+= -DWITH_PHP=1 >-PLIST_SUB+= PHP_EXTENSION_DIR=${PHP_EXTENSION_DIR} > PLIST_SUB+= PHP="" > .else > CMAKE_ARGS+= -DWITH_PHP=0 >@@ -188,23 +186,21 @@ do-install: > .endfor > ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/libmapserver.so.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib > >-.if ${PORT_OPTIONS:MPHP} >- @${MKDIR} ${STAGEDIR}${PREFIX}/${PHP_EXTENSION_DIR} >+do-install-PHP-on: >+ @${MKDIR} ${STAGEDIR}${PREFIX}/lib/php/${PHP_EXT_DIR} > ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/mapscript/php/php_mapscript.so \ >- ${STAGEDIR}${PREFIX}/${PHP_EXTENSION_DIR}/ >-.endif >+ ${STAGEDIR}${PREFIX}/lib/php/${PHP_EXT_DIR}/ > >-.if ${PORT_OPTIONS:MPYTHON} >+do-install-PYTHON-on: > @${MKDIR} ${STAGEDIR}${PYTHON_SITELIBDIR}/ > (cd ${BUILD_WRKSRC}/mapscript/python && ${CP} mapscript.py _mapscript.so ${STAGEDIR}${PYTHON_SITELIBDIR}/) >-.endif > > post-install: > @${LN} -s ${PREFIX}/lib/libmapserver.so.7.0.1 ${STAGEDIR}${PREFIX}/lib/libmapserver.so.2 > @${LN} -s ${PREFIX}/lib/libmapserver.so.2 ${STAGEDIR}${PREFIX}/lib/libmapserver.so > >-.if ${PORT_OPTIONS:MPHP} >- @${ECHO_MSG} "Please add the line extension=php_mapscript.so to ${PREFIX}/etc/php/extensions.ini" >-.endif >+post-install-PHP-on: >+ @${MKDIR} ${STAGEDIR}${PREFIX}/etc/php >+ @${ECHO_CMD} "extension=php_mapscript.so" > ${STAGEDIR}${PREFIX}/etc/php/ext-20-php_mapscript.ini > > .include <bsd.port.mk> >diff --git graphics/mapserver/pkg-plist graphics/mapserver/pkg-plist >index 85d35e2..2a5cc26 100644 >--- graphics/mapserver/pkg-plist >+++ graphics/mapserver/pkg-plist >@@ -8,9 +8,10 @@ bin/shptreetst > bin/shptreevis > bin/sortshp > bin/tile4ms >+%%PHP%%etc/php/ext-20-php_mapscript.ini > lib/libmapserver.so > lib/libmapserver.so.2 > lib/libmapserver.so.7.0.1 >-%%PHP%%%%PHP_EXTENSION_DIR%%/php_mapscript.so >+%%PHP%%lib/php/%%PHP_EXT_DIR%%/php_mapscript.so > %%PYTHON%%%%PYTHON_SITELIBDIR%%/mapscript.py > %%PYTHON%%%%PYTHON_SITELIBDIR%%/_mapscript.so >diff --git lang/php55/Makefile.ext lang/php55/Makefile.ext >index 210c6ec..53547f2 100644 >--- lang/php55/Makefile.ext >+++ lang/php55/Makefile.ext >@@ -217,6 +217,8 @@ USE_OPENSSL= yes > .endif > > .if ${PHP_MODNAME} == "opcache" >+# This is needed by Zend extensions, keep before everything. >+PHP_MOD_PRIO= 10 > CONFIGURE_ARGS+=--enable-opcache > .endif > >diff --git lang/php56/Makefile.ext lang/php56/Makefile.ext >index 609fcbf..e2d38cf 100644 >--- lang/php56/Makefile.ext >+++ lang/php56/Makefile.ext >@@ -217,6 +217,8 @@ USE_OPENSSL= yes > .endif > > .if ${PHP_MODNAME} == "opcache" >+# This is needed by Zend extensions, keep before everything. >+PHP_MOD_PRIO= 10 > CONFIGURE_ARGS+=--enable-opcache > .endif > >diff --git lang/php70/Makefile.ext lang/php70/Makefile.ext >index 2d1b831..ffa75e1 100644 >--- lang/php70/Makefile.ext >+++ lang/php70/Makefile.ext >@@ -209,6 +209,8 @@ USE_OPENSSL= yes > .endif > > .if ${PHP_MODNAME} == "opcache" >+# This is needed by Zend extensions, keep before everything. >+PHP_MOD_PRIO= 10 > CONFIGURE_ARGS+=--enable-opcache > USES+= localbase > .endif
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 210697
:
171947
|
172751
|
173040