1 |
commit: 2bc9e720b51592ab68209d2348aca6767e8cc129 |
2 |
Author: Brian Evans <grknight <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Aug 14 12:42:14 2019 +0000 |
4 |
Commit: Brian Evans <grknight <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Aug 14 12:42:14 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2bc9e720 |
7 |
|
8 |
dev-lang/php: Drop vulnerable versions |
9 |
|
10 |
Bug: https://bugs.gentoo.org/691564 |
11 |
Package-Manager: Portage-2.3.71, Repoman-2.3.17 |
12 |
Signed-off-by: Brian Evans <grknight <AT> gentoo.org> |
13 |
|
14 |
dev-lang/php/Manifest | 4 - |
15 |
dev-lang/php/php-5.6.40-r4.ebuild | 789 -------------------------------------- |
16 |
dev-lang/php/php-7.1.30.ebuild | 737 ----------------------------------- |
17 |
dev-lang/php/php-7.2.20.ebuild | 749 ------------------------------------ |
18 |
dev-lang/php/php-7.3.7-r1.ebuild | 750 ------------------------------------ |
19 |
5 files changed, 3029 deletions(-) |
20 |
|
21 |
diff --git a/dev-lang/php/Manifest b/dev-lang/php/Manifest |
22 |
index c21fbe5c5bd..f34d859eaa1 100644 |
23 |
--- a/dev-lang/php/Manifest |
24 |
+++ b/dev-lang/php/Manifest |
25 |
@@ -1,10 +1,6 @@ |
26 |
DIST php-5.6.40.tar.xz 12472236 BLAKE2B f41147eaec9b15e965540f9e871691cc88848dd619bae6af85e7bba0130b71ce91bad5cdbbadbb537c42df83369f5c731007339a9d9e21e689e913c135201afc SHA512 997b5a952a60cf9166671cc91fcc34c674dd62bfd5cb0a9cdf3fdf2d088b5d19943d94c1cf193f8ab71fc4957d9a9a4c7c2fb8826f937501c1c0a0858f10e329 |
27 |
-DIST php-7.1.30.tar.xz 12221980 BLAKE2B 7b2550e8f1c3cbd40223d9ed1d3e9e7a32550a057ecf0c83ce105a5e17805a57266130830adf60adeb4bbcd4cb787539a04783b0588d84e9771ce036de8b176e SHA512 7c6654e118931a8dab4896a7b62221b863b5a235a9bbce3e0c09abf5e55b964f86b1d2b2c96683b09254829c2569e72620f4d8d50cd05153ee56617e62ad37c1 |
28 |
DIST php-7.1.31.tar.xz 12370928 BLAKE2B 18b7d5398380324243321a39d337bd10a7eb82812f3dbb9b2ea9eb4808ef585d6452cc5953b56d24bcf817994e249b8b20cd9b4658e1df6c77de78eecb48a3a7 SHA512 989cd157e0d67c6f03192ce9e1afaa01ff72ccc83f3e6b94ac8dc3d4c2717258a46bd64fb20e4649baec1fe2545805013eedc1de78e556d09c2b0ae64d4272d8 |
29 |
-DIST php-7.2.20.tar.xz 12183712 BLAKE2B d163afbc56c0d32a3d0f24d3db2c4016a71bb745642f27a01bdfbe29015106f5708ee3aabfc482b01f48c147ca9e28e9b6d1da613284bc3d35651e2aa0862940 SHA512 7c61b7277181f70a8abae560e72f765f598712afe9be6cef0b9a50402e0eca74b773237866e0375e41a4e6f76111035c92e823120a4be2b7647517b01ef6b5c7 |
30 |
DIST php-7.2.21.tar.xz 12298448 BLAKE2B f82b35fd3cdf45d8c84639d044729602340c2d34695b5603a194e2d504627c0e041ab156c3720d218d8d6ca51c9ef71d8d0ee37585142aa30ed0cce51fbcb91e SHA512 c7fe01626c1e25e8882d8f2b69d77a5479567d2daa3bf25d1ce3f45314a882f79ce9914a2aa1b3052b6289b46873f466e457049ce1db6e31b60ba4995187507c |
31 |
-DIST php-7.3.7.tar.xz 11993760 BLAKE2B 0d634171825b9fd0a831a45486f4d67142bf592042571025a26d8a01e236ef6735af11cffb645ca19d245fe56f1b0085b32545360668b68686524f4307898d07 SHA512 583a28aa346c3322998bfda81bf00f2f2b84ff1e2311f0877288d7d4f02639e953e9bd8cb59372cd4bec9aeffa3ec00375c4b03a3ee8ec1db05a095a28164908 |
32 |
DIST php-7.3.8.tar.xz 12064620 BLAKE2B cfe2fde5e48080e13bd21cb2e2ca0c0ae38da03c94d0692e11bfe6722e50bd0b864d629a0ef6aed4ac5d9830ec4b4b214b9abdf917519a0c0cb70a4362fc8390 SHA512 9e9e13845350f3d4a8a80c3e2fe8291996e2749b2c862261b96346c01e5e24640cb81adad5e3b7668b56b2266c1fcbb713e8c38da4f9aa474f5f632f91378a8d |
33 |
DIST php-7.4.0beta1.tar.xz 10200060 BLAKE2B f49c49fcebe0309bbe266dec5c468037499fc96908a4130454403e57caa3ef7da3c46dbc83829bb290c46edfc14921f71fafddb8b0777c23adec35fbb57ad68c SHA512 3e4307201c91cec238c9bc6c27a629a93de8baba0307f2e61cb4bb242720178382dd50b38e7a18fbd65baf25068b358faf571dcb895e7cd6fb292038dee3ed6b |
34 |
-DIST php-patches-7.1.30bp.tar.bz2 30698 BLAKE2B 74bbab7e3d721ce823f1820b9fad1dd61c9b109e50392ae6cf08f9ae1f6b813273d50edad2644913b016b369f6fc32ff5bf1abe0687c23876596f3f18ec20e1a SHA512 832f97636a346c88089190dc0a0d98d39ef69244b441e553a7775da602227338f1f4a6cb90295b4f5fb117f6c64b259120840dbfe0da7352819d94392aff9fd6 |
35 |
DIST php-patches-7.1.31bp.tar.bz2 37219 BLAKE2B 4f3ead2f69adf00ac1317371172c8adbb823f597cd8e3cafe7044d6a46671437fd2e5eaef4309a6fd5825123394044543284d3cbe892c918353a5b07c12b7401 SHA512 eb52679d035ceb4124c8e9175024f4f753e20d139479af4a57e01de941991716b2ce37f6190242c1bec46fd5305bad1f91613b04ee849a0d94f4a33ce013781e |
36 |
|
37 |
diff --git a/dev-lang/php/php-5.6.40-r4.ebuild b/dev-lang/php/php-5.6.40-r4.ebuild |
38 |
deleted file mode 100644 |
39 |
index 27584191b82..00000000000 |
40 |
--- a/dev-lang/php/php-5.6.40-r4.ebuild |
41 |
+++ /dev/null |
42 |
@@ -1,789 +0,0 @@ |
43 |
-# Copyright 1999-2019 Gentoo Authors |
44 |
-# Distributed under the terms of the GNU General Public License v2 |
45 |
- |
46 |
-EAPI="7" |
47 |
- |
48 |
-inherit autotools flag-o-matic systemd |
49 |
- |
50 |
-PATCH_V="7.1.30bp" |
51 |
- |
52 |
-DESCRIPTION="The PHP language runtime engine" |
53 |
-HOMEPAGE="https://secure.php.net/" |
54 |
-SRC_URI="https://php.net/distributions/${P}.tar.xz |
55 |
- https://gitweb.gentoo.org/proj/php-patches.git/snapshot/php-patches-${PATCH_V}.tar.bz2" |
56 |
- |
57 |
-LICENSE="PHP-3.01 |
58 |
- BSD |
59 |
- Zend-2.0 |
60 |
- bcmath? ( LGPL-2.1+ ) |
61 |
- fpm? ( BSD-2 ) |
62 |
- gd? ( gd ) |
63 |
- unicode? ( BSD-2 LGPL-2.1 )" |
64 |
- |
65 |
-SLOT="$(ver_cut 1-2)" |
66 |
-KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos" |
67 |
- |
68 |
-# We can build the following SAPIs in the given order |
69 |
-SAPIS="embed cli cgi fpm apache2" |
70 |
- |
71 |
-# SAPIs and SAPI-specific USE flags (cli SAPI is default on): |
72 |
-IUSE="${IUSE} |
73 |
- ${SAPIS/cli/+cli} |
74 |
- threads" |
75 |
- |
76 |
-IUSE="${IUSE} acl bcmath berkdb bzip2 calendar cdb cjk |
77 |
- coverage crypt +ctype curl debug |
78 |
- enchant exif +fileinfo +filter firebird |
79 |
- flatfile ftp gd gdbm gmp +hash +iconv imap inifile |
80 |
- intl iodbc ipv6 +json kerberos ldap ldap-sasl libedit libressl |
81 |
- mhash mssql mysql libmysqlclient mysqli nls |
82 |
- oci8-instant-client odbc +opcache pcntl pdo +phar +posix postgres qdbm |
83 |
- readline recode selinux +session sharedmem |
84 |
- +simplexml snmp soap sockets spell sqlite ssl |
85 |
- sybase-ct sysvipc systemd tidy +tokenizer truetype unicode vpx wddx |
86 |
- +xml xmlreader xmlwriter xmlrpc xpm xslt zip zlib" |
87 |
- |
88 |
-# The supported (that is, autodetected) versions of BDB are listed in |
89 |
-# the ./configure script. Other versions *work*, but we need to stick to |
90 |
-# the ones that can be detected to avoid a repeat of bug #564824. |
91 |
-COMMON_DEPEND=" |
92 |
- >=app-eselect/eselect-php-0.9.1[apache2?,fpm?] |
93 |
- >=dev-libs/libpcre-8.32[unicode] |
94 |
- fpm? ( acl? ( sys-apps/acl ) ) |
95 |
- apache2? ( || ( >=www-servers/apache-2.4[apache2_modules_unixd,threads=] |
96 |
- <www-servers/apache-2.4[threads=] ) ) |
97 |
- berkdb? ( || ( sys-libs/db:5.3 |
98 |
- sys-libs/db:5.1 |
99 |
- sys-libs/db:4.8 |
100 |
- sys-libs/db:4.7 |
101 |
- sys-libs/db:4.6 |
102 |
- sys-libs/db:4.5 ) ) |
103 |
- bzip2? ( app-arch/bzip2:0= ) |
104 |
- cdb? ( || ( dev-db/cdb dev-db/tinycdb ) ) |
105 |
- cjk? ( !gd? ( |
106 |
- virtual/jpeg:0 |
107 |
- media-libs/libpng:0= |
108 |
- sys-libs/zlib:0= |
109 |
- ) ) |
110 |
- coverage? ( dev-util/lcov ) |
111 |
- crypt? ( >=dev-libs/libmcrypt-2.4 ) |
112 |
- curl? ( >=net-misc/curl-7.10.5 ) |
113 |
- enchant? ( app-text/enchant ) |
114 |
- exif? ( !gd? ( |
115 |
- virtual/jpeg:0 |
116 |
- media-libs/libpng:0= |
117 |
- sys-libs/zlib:0= |
118 |
- ) ) |
119 |
- firebird? ( dev-db/firebird ) |
120 |
- gd? ( virtual/jpeg:0 media-libs/libpng:0= sys-libs/zlib:0= ) |
121 |
- gdbm? ( >=sys-libs/gdbm-1.8.0:0= ) |
122 |
- gmp? ( dev-libs/gmp:0= ) |
123 |
- iconv? ( virtual/libiconv ) |
124 |
- imap? ( virtual/imap-c-client[kerberos=,ssl=] ) |
125 |
- intl? ( dev-libs/icu:= ) |
126 |
- iodbc? ( dev-db/libiodbc ) |
127 |
- kerberos? ( virtual/krb5 ) |
128 |
- ldap? ( >=net-nds/openldap-1.2.11 ) |
129 |
- ldap-sasl? ( dev-libs/cyrus-sasl >=net-nds/openldap-1.2.11 ) |
130 |
- libedit? ( || ( sys-freebsd/freebsd-lib dev-libs/libedit ) ) |
131 |
- mssql? ( dev-db/freetds[mssql] ) |
132 |
- libmysqlclient? ( |
133 |
- mysql? ( virtual/libmysqlclient:= ) |
134 |
- mysqli? ( virtual/libmysqlclient:= ) |
135 |
- ) |
136 |
- nls? ( sys-devel/gettext ) |
137 |
- oci8-instant-client? ( dev-db/oracle-instantclient-basic ) |
138 |
- odbc? ( >=dev-db/unixODBC-1.8.13 ) |
139 |
- postgres? ( dev-db/postgresql:* ) |
140 |
- qdbm? ( dev-db/qdbm ) |
141 |
- readline? ( sys-libs/readline:0= ) |
142 |
- recode? ( app-text/recode ) |
143 |
- sharedmem? ( dev-libs/mm ) |
144 |
- simplexml? ( >=dev-libs/libxml2-2.6.8 ) |
145 |
- snmp? ( >=net-analyzer/net-snmp-5.2 ) |
146 |
- soap? ( >=dev-libs/libxml2-2.6.8 ) |
147 |
- spell? ( >=app-text/aspell-0.50 ) |
148 |
- sqlite? ( >=dev-db/sqlite-3.7.6.3 ) |
149 |
- ssl? ( |
150 |
- !libressl? ( dev-libs/openssl:0= ) |
151 |
- libressl? ( dev-libs/libressl:0= ) |
152 |
- ) |
153 |
- sybase-ct? ( dev-db/freetds ) |
154 |
- tidy? ( app-text/htmltidy ) |
155 |
- truetype? ( |
156 |
- =media-libs/freetype-2* |
157 |
- >=media-libs/t1lib-5.0.0 |
158 |
- !gd? ( |
159 |
- virtual/jpeg:0 media-libs/libpng:0= sys-libs/zlib:0= ) |
160 |
- ) |
161 |
- unicode? ( dev-libs/oniguruma:= ) |
162 |
- vpx? ( media-libs/libvpx:0= ) |
163 |
- wddx? ( >=dev-libs/libxml2-2.6.8 ) |
164 |
- xml? ( >=dev-libs/libxml2-2.6.8 ) |
165 |
- xmlrpc? ( >=dev-libs/libxml2-2.6.8 virtual/libiconv ) |
166 |
- xmlreader? ( >=dev-libs/libxml2-2.6.8 ) |
167 |
- xmlwriter? ( >=dev-libs/libxml2-2.6.8 ) |
168 |
- xpm? ( |
169 |
- x11-libs/libXpm |
170 |
- virtual/jpeg:0 |
171 |
- media-libs/libpng:0= sys-libs/zlib:0= |
172 |
- ) |
173 |
- xslt? ( dev-libs/libxslt >=dev-libs/libxml2-2.6.8 ) |
174 |
- zip? ( sys-libs/zlib:0= ) |
175 |
- zlib? ( sys-libs/zlib:0= ) |
176 |
-" |
177 |
- |
178 |
-RDEPEND="${COMMON_DEPEND} |
179 |
- virtual/mta |
180 |
- fpm? ( |
181 |
- selinux? ( sec-policy/selinux-phpfpm ) |
182 |
- systemd? ( sys-apps/systemd ) )" |
183 |
- |
184 |
-DEPEND="${COMMON_DEPEND} |
185 |
- app-arch/xz-utils |
186 |
- >=sys-devel/bison-3.0.1 |
187 |
- sys-devel/flex |
188 |
- >=sys-devel/m4-1.4.3 |
189 |
- >=sys-devel/libtool-1.5.18" |
190 |
- |
191 |
-# Without USE=readline or libedit, the interactive "php -a" CLI will hang. |
192 |
-REQUIRED_USE=" |
193 |
- || ( cli cgi fpm apache2 embed ) |
194 |
- cli? ( ^^ ( readline libedit ) ) |
195 |
- truetype? ( gd zlib ) |
196 |
- vpx? ( gd zlib ) |
197 |
- cjk? ( gd zlib ) |
198 |
- exif? ( gd zlib ) |
199 |
- xpm? ( gd zlib ) |
200 |
- gd? ( zlib ) |
201 |
- simplexml? ( xml ) |
202 |
- soap? ( xml ) |
203 |
- wddx? ( xml ) |
204 |
- xmlrpc? ( || ( xml iconv ) ) |
205 |
- xmlreader? ( xml ) |
206 |
- xslt? ( xml ) |
207 |
- ldap-sasl? ( ldap ) |
208 |
- mhash? ( hash ) |
209 |
- phar? ( hash ) |
210 |
- recode? ( !imap !mysql !mysqli !libmysqlclient ) |
211 |
- libmysqlclient? ( || ( |
212 |
- mysql |
213 |
- mysqli |
214 |
- pdo |
215 |
- ) ) |
216 |
- |
217 |
- qdbm? ( !gdbm ) |
218 |
- readline? ( !libedit ) |
219 |
- sharedmem? ( !threads ) |
220 |
-" |
221 |
- |
222 |
-PHP_MV="$(ver_cut 1)" |
223 |
- |
224 |
-php_install_ini() { |
225 |
- local phpsapi="${1}" |
226 |
- |
227 |
- # work out where we are installing the ini file |
228 |
- php_set_ini_dir "${phpsapi}" |
229 |
- |
230 |
- # Always install the production INI file, bug 611214. |
231 |
- local phpinisrc="php.ini-production-${phpsapi}" |
232 |
- cp php.ini-production "${phpinisrc}" || die |
233 |
- |
234 |
- # default to /tmp for save_path, bug #282768 |
235 |
- sed -e 's|^;session.save_path .*$|session.save_path = "'"${EPREFIX}"'/tmp"|g' -i "${phpinisrc}" || die |
236 |
- |
237 |
- # Set the extension dir |
238 |
- sed -e "s|^extension_dir .*$|extension_dir = ${extension_dir}|g" \ |
239 |
- -i "${phpinisrc}" || die |
240 |
- |
241 |
- # Set the include path to point to where we want to find PEAR packages |
242 |
- sed -e 's|^;include_path = ".:/php/includes".*|include_path = ".:'"${EPREFIX}"'/usr/share/php'${PHP_MV}':'"${EPREFIX}"'/usr/share/php"|' -i "${phpinisrc}" || die |
243 |
- |
244 |
- dodir "${PHP_INI_DIR#${EPREFIX}}" |
245 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
246 |
- newins "${phpinisrc}" php.ini |
247 |
- |
248 |
- elog "Installing php.ini for ${phpsapi} into ${PHP_INI_DIR#${EPREFIX}}" |
249 |
- elog |
250 |
- |
251 |
- dodir "${PHP_EXT_INI_DIR#${EPREFIX}}" |
252 |
- dodir "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}" |
253 |
- |
254 |
- if use opcache; then |
255 |
- elog "Adding opcache to $PHP_EXT_INI_DIR" |
256 |
- echo "zend_extension=${PHP_DESTDIR}/$(get_libdir)/opcache.so" >> \ |
257 |
- "${D}/${PHP_EXT_INI_DIR}"/opcache.ini |
258 |
- dosym "${PHP_EXT_INI_DIR#${EPREFIX}}/opcache.ini" \ |
259 |
- "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}/opcache.ini" |
260 |
- fi |
261 |
- |
262 |
- # SAPI-specific handling |
263 |
- if [[ "${sapi}" == "fpm" ]] ; then |
264 |
- einfo "Installing FPM config file php-fpm.conf" |
265 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
266 |
- doins sapi/fpm/php-fpm.conf |
267 |
- fi |
268 |
- |
269 |
- dodoc php.ini-{development,production} |
270 |
-} |
271 |
- |
272 |
-php_set_ini_dir() { |
273 |
- PHP_INI_DIR="${EPREFIX}/etc/php/${1}-php${SLOT}" |
274 |
- PHP_EXT_INI_DIR="${PHP_INI_DIR}/ext" |
275 |
- PHP_EXT_INI_DIR_ACTIVE="${PHP_INI_DIR}/ext-active" |
276 |
-} |
277 |
- |
278 |
-src_prepare() { |
279 |
- local patchdir="${WORKDIR}/php-patches-${PATCH_V}" |
280 |
- |
281 |
- eapply "${patchdir}/" |
282 |
- |
283 |
- # Copy test binaries from patches |
284 |
- local ext_src |
285 |
- for ext_src in exif iconv ; do |
286 |
- cp "${patchdir}/${ext_src}/"* "ext/${ext_src}/tests/" || die |
287 |
- done |
288 |
- |
289 |
- # Change PHP branding |
290 |
- # Get the alpha/beta/rc version |
291 |
- sed -re "s|^(PHP_EXTRA_VERSION=\").*(\")|\1-pl${PR/r/}-gentoo\2|g" \ |
292 |
- -i configure.in || die "Unable to change PHP branding" |
293 |
- |
294 |
- # Patch PHP to show Gentoo as the server platform |
295 |
- sed -e 's/PHP_UNAME=`uname -a | xargs`/PHP_UNAME=`uname -s -n -r -v | xargs`/g' \ |
296 |
- -i configure.in || die "Failed to fix server platform name" |
297 |
- |
298 |
- # Prevent PHP from activating the Apache config, |
299 |
- # as we will do that ourselves |
300 |
- sed -i \ |
301 |
- -e "s,-i -a -n php${PHP_MV},-i -n php${PHP_MV},g" \ |
302 |
- -e "s,-i -A -n php${PHP_MV},-i -n php${PHP_MV},g" \ |
303 |
- configure sapi/apache2filter/config.m4 sapi/apache2handler/config.m4 \ |
304 |
- || die |
305 |
- |
306 |
- # Patch PHP to support heimdal instead of mit-krb5 |
307 |
- if has_version "app-crypt/heimdal" ; then |
308 |
- sed -e 's|gssapi_krb5|gssapi|g' -i acinclude.m4 \ |
309 |
- || die "Failed to fix heimdal libname" |
310 |
- sed -e 's|PHP_ADD_LIBRARY(k5crypto, 1, $1)||g' -i acinclude.m4 \ |
311 |
- || die "Failed to fix heimdal crypt library reference" |
312 |
- fi |
313 |
- |
314 |
- eapply_user |
315 |
- |
316 |
- # Force rebuilding aclocal.m4 |
317 |
- rm -f aclocal.m4 || die "failed to remove aclocal.m4 in src_prepare" |
318 |
- |
319 |
- mv configure.in configure.ac || die |
320 |
- |
321 |
- eautoreconf |
322 |
- |
323 |
- if [[ ${CHOST} == *-darwin* ]] ; then |
324 |
- # http://bugs.php.net/bug.php?id=48795, bug #343481 |
325 |
- sed -i -e '/BUILD_CGI="\\$(CC)/s/CC/CXX/' configure || die |
326 |
- fi |
327 |
-} |
328 |
- |
329 |
-src_configure() { |
330 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
331 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
332 |
- |
333 |
- PHP_DESTDIR="${EPREFIX}/usr/$(get_libdir)/php${SLOT}" |
334 |
- |
335 |
- # The php-fpm config file wants localstatedir to be ${EPREFIX}/var |
336 |
- # and not the Gentoo default ${EPREFIX}/var/lib. See bug 572002. |
337 |
- local our_conf=( |
338 |
- --prefix="${PHP_DESTDIR}" |
339 |
- --mandir="${PHP_DESTDIR}/man" |
340 |
- --infodir="${PHP_DESTDIR}/info" |
341 |
- --libdir="${PHP_DESTDIR}/lib" |
342 |
- --with-libdir="$(get_libdir)" |
343 |
- --localstatedir="${EPREFIX}/var" |
344 |
- --without-pear |
345 |
- $(use_enable threads maintainer-zts) |
346 |
- ) |
347 |
- |
348 |
- our_conf+=( |
349 |
- $(use_enable bcmath bcmath) |
350 |
- $(use_with bzip2 bz2 "${EPREFIX}/usr") |
351 |
- $(use_enable calendar calendar) |
352 |
- $(use_enable coverage gcov) |
353 |
- $(use_enable ctype ctype) |
354 |
- $(use_with curl curl "${EPREFIX}/usr") |
355 |
- $(use_enable xml dom) |
356 |
- $(use_with enchant enchant "${EPREFIX}/usr") |
357 |
- $(use_enable exif exif) |
358 |
- $(use_enable fileinfo fileinfo) |
359 |
- $(use_enable filter filter) |
360 |
- $(use_enable ftp ftp) |
361 |
- $(use_with nls gettext "${EPREFIX}/usr") |
362 |
- $(use_with gmp gmp "${EPREFIX}/usr") |
363 |
- $(use_enable hash hash) |
364 |
- $(use_with mhash mhash "${EPREFIX}/usr") |
365 |
- $(use_with iconv iconv \ |
366 |
- $(use elibc_glibc || use elibc_musl || use elibc_FreeBSD || echo "${EPREFIX}/usr")) |
367 |
- $(use_enable intl intl) |
368 |
- $(use_enable ipv6 ipv6) |
369 |
- $(use_enable json json) |
370 |
- $(use_with kerberos kerberos "${EPREFIX}/usr") |
371 |
- $(use_enable xml libxml) |
372 |
- $(use_with xml libxml-dir "${EPREFIX}/usr") |
373 |
- $(use_enable unicode mbstring) |
374 |
- $(use_with crypt mcrypt "${EPREFIX}/usr") |
375 |
- $(use_with mssql mssql "${EPREFIX}/usr") |
376 |
- $(use_with unicode onig "${EPREFIX}/usr") |
377 |
- $(use_with ssl openssl "${EPREFIX}/usr") |
378 |
- $(use_with ssl openssl-dir "${EPREFIX}/usr") |
379 |
- $(use_enable pcntl pcntl) |
380 |
- $(use_enable phar phar) |
381 |
- $(use_enable pdo pdo) |
382 |
- $(use_enable opcache opcache) |
383 |
- $(use_with postgres pgsql "${EPREFIX}/usr") |
384 |
- $(use_enable posix posix) |
385 |
- $(use_with spell pspell "${EPREFIX}/usr") |
386 |
- $(use_with recode recode "${EPREFIX}/usr") |
387 |
- $(use_enable simplexml simplexml) |
388 |
- $(use_enable sharedmem shmop) |
389 |
- $(use_with snmp snmp "${EPREFIX}/usr") |
390 |
- $(use_enable soap soap) |
391 |
- $(use_enable sockets sockets) |
392 |
- $(use_with sqlite sqlite3 "${EPREFIX}/usr") |
393 |
- $(use_with sybase-ct sybase-ct "${EPREFIX}/usr") |
394 |
- $(use_enable sysvipc sysvmsg) |
395 |
- $(use_enable sysvipc sysvsem) |
396 |
- $(use_enable sysvipc sysvshm) |
397 |
- $(use_with tidy tidy "${EPREFIX}/usr") |
398 |
- $(use_enable tokenizer tokenizer) |
399 |
- $(use_enable wddx wddx) |
400 |
- $(use_enable xml xml) |
401 |
- $(use_enable xmlreader xmlreader) |
402 |
- $(use_enable xmlwriter xmlwriter) |
403 |
- $(use_with xmlrpc xmlrpc) |
404 |
- $(use_with xslt xsl "${EPREFIX}/usr") |
405 |
- $(use_enable zip zip) |
406 |
- $(use_with zlib zlib "${EPREFIX}/usr") |
407 |
- $(use_enable debug debug) |
408 |
- ) |
409 |
- |
410 |
- # DBA support |
411 |
- if use cdb || use berkdb || use flatfile || use gdbm || use inifile \ |
412 |
- || use qdbm ; then |
413 |
- our_conf+=( "--enable-dba${shared}" ) |
414 |
- fi |
415 |
- |
416 |
- # DBA drivers support |
417 |
- our_conf+=( |
418 |
- $(use_with cdb cdb) |
419 |
- $(use_with berkdb db4 "${EPREFIX}/usr") |
420 |
- $(use_enable flatfile flatfile) |
421 |
- $(use_with gdbm gdbm "${EPREFIX}/usr") |
422 |
- $(use_enable inifile inifile) |
423 |
- $(use_with qdbm qdbm "${EPREFIX}/usr") |
424 |
- ) |
425 |
- |
426 |
- # Support for the GD graphics library |
427 |
- our_conf+=( |
428 |
- $(use_with truetype freetype-dir "${EPREFIX}/usr") |
429 |
- $(use_with truetype t1lib "${EPREFIX}/usr") |
430 |
- $(use_enable cjk gd-jis-conv) |
431 |
- $(use_with gd jpeg-dir "${EPREFIX}/usr") |
432 |
- $(use_with gd png-dir "${EPREFIX}/usr") |
433 |
- $(use_with xpm xpm-dir "${EPREFIX}/usr") |
434 |
- $(use_with vpx vpx-dir "${EPREFIX}/usr") |
435 |
- ) |
436 |
- # enable gd last, so configure can pick up the previous settings |
437 |
- our_conf+=( $(use_with gd gd) ) |
438 |
- |
439 |
- # IMAP support |
440 |
- if use imap ; then |
441 |
- our_conf+=( |
442 |
- $(use_with imap imap "${EPREFIX}/usr") |
443 |
- $(use_with ssl imap-ssl "${EPREFIX}/usr") |
444 |
- ) |
445 |
- fi |
446 |
- |
447 |
- # Interbase/firebird support |
448 |
- our_conf+=( $(use_with firebird interbase "${EPREFIX}/usr") ) |
449 |
- |
450 |
- # LDAP support |
451 |
- if use ldap ; then |
452 |
- our_conf+=( |
453 |
- $(use_with ldap ldap "${EPREFIX}/usr") |
454 |
- $(use_with ldap-sasl ldap-sasl "${EPREFIX}/usr") |
455 |
- ) |
456 |
- fi |
457 |
- |
458 |
- # MySQL support |
459 |
- local mysqllib="mysqlnd" |
460 |
- local mysqlilib="mysqlnd" |
461 |
- use libmysqlclient && mysqllib="${EPREFIX}/usr" |
462 |
- use libmysqlclient && mysqlilib="${EPREFIX}/usr/bin/mysql_config" |
463 |
- |
464 |
- our_conf+=( $(use_with mysql mysql "${mysqllib}") ) |
465 |
- our_conf+=( $(use_with mysqli mysqli "${mysqlilib}") ) |
466 |
- |
467 |
- local mysqlsock="${EPREFIX}/var/run/mysqld/mysqld.sock" |
468 |
- if use mysql || use mysqli ; then |
469 |
- our_conf+=( $(use_with mysql mysql-sock "${mysqlsock}") ) |
470 |
- fi |
471 |
- |
472 |
- # ODBC support |
473 |
- our_conf+=( |
474 |
- $(use_with odbc unixODBC "${EPREFIX}/usr") |
475 |
- $(use_with iodbc iodbc "${EPREFIX}/usr") |
476 |
- ) |
477 |
- |
478 |
- # Oracle support |
479 |
- our_conf+=( $(use_with oci8-instant-client oci8) ) |
480 |
- |
481 |
- # PDO support |
482 |
- if use pdo ; then |
483 |
- our_conf+=( |
484 |
- $(use_with mssql pdo-dblib) |
485 |
- $(use_with mysql pdo-mysql "${mysqllib}") |
486 |
- $(use_with postgres pdo-pgsql) |
487 |
- $(use_with sqlite pdo-sqlite "${EPREFIX}/usr") |
488 |
- $(use_with firebird pdo-firebird "${EPREFIX}/usr") |
489 |
- $(use_with odbc pdo-odbc "unixODBC,${EPREFIX}/usr") |
490 |
- $(use_with oci8-instant-client pdo-oci) |
491 |
- ) |
492 |
- fi |
493 |
- |
494 |
- # readline/libedit support |
495 |
- our_conf+=( |
496 |
- $(use_with readline readline "${EPREFIX}/usr") |
497 |
- $(use_with libedit libedit "${EPREFIX}/usr") |
498 |
- ) |
499 |
- |
500 |
- # Session support |
501 |
- if use session ; then |
502 |
- our_conf+=( $(use_with sharedmem mm "${EPREFIX}/usr") ) |
503 |
- else |
504 |
- our_conf+=( $(use_enable session session) ) |
505 |
- fi |
506 |
- |
507 |
- # Use pic for shared modules such as apache2's mod_php |
508 |
- our_conf+=( --with-pic ) |
509 |
- |
510 |
- # we use the system copy of pcre |
511 |
- # --with-pcre-regex affects ext/pcre |
512 |
- # --with-pcre-dir affects ext/filter and ext/zip |
513 |
- our_conf+=( |
514 |
- --with-pcre-regex="${EPREFIX}/usr" |
515 |
- --with-pcre-dir="${EPREFIX}/usr" |
516 |
- ) |
517 |
- |
518 |
- # Catch CFLAGS problems |
519 |
- # Fixes bug #14067. |
520 |
- # Changed order to run it in reverse for bug #32022 and #12021. |
521 |
- replace-cpu-flags "k6*" "i586" |
522 |
- |
523 |
- # Cache the ./configure test results between SAPIs. |
524 |
- our_conf+=( --cache-file="${T}/config.cache" ) |
525 |
- |
526 |
- # Support user-passed configuration parameters |
527 |
- our_conf+=( ${EXTRA_ECONF:-} ) |
528 |
- |
529 |
- # Support the Apache2 extras, they must be set globally for all |
530 |
- # SAPIs to work correctly, especially for external PHP extensions |
531 |
- |
532 |
- mkdir -p "${WORKDIR}/sapis-build" || die |
533 |
- for one_sapi in $SAPIS ; do |
534 |
- use "${one_sapi}" || continue |
535 |
- php_set_ini_dir "${one_sapi}" |
536 |
- |
537 |
- # The BUILD_DIR variable is used to determine where to output |
538 |
- # the files that autotools creates. This was all originally |
539 |
- # based on the autotools-utils eclass. |
540 |
- BUILD_DIR="${WORKDIR}/sapis-build/${one_sapi}" |
541 |
- cp -a "${S}" "${BUILD_DIR}" || die |
542 |
- cd "${BUILD_DIR}" || die |
543 |
- |
544 |
- local sapi_conf=( |
545 |
- --with-config-file-path="${PHP_INI_DIR}" |
546 |
- --with-config-file-scan-dir="${PHP_EXT_INI_DIR_ACTIVE}" |
547 |
- ) |
548 |
- |
549 |
- for sapi in $SAPIS ; do |
550 |
- case "$sapi" in |
551 |
- cli|cgi|embed|fpm) |
552 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
553 |
- sapi_conf+=( "--enable-${sapi}" ) |
554 |
- if [[ "fpm" == "${sapi}" ]] ; then |
555 |
- sapi_conf+=( |
556 |
- $(use_with acl fpm-acl) |
557 |
- $(use_with systemd fpm-systemd) |
558 |
- ) |
559 |
- fi |
560 |
- else |
561 |
- sapi_conf+=( "--disable-${sapi}" ) |
562 |
- fi |
563 |
- ;; |
564 |
- |
565 |
- apache2) |
566 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
567 |
- sapi_conf+=( --with-apxs2="${EPREFIX}/usr/bin/apxs" ) |
568 |
- else |
569 |
- sapi_conf+=( --without-apxs2 ) |
570 |
- fi |
571 |
- ;; |
572 |
- esac |
573 |
- done |
574 |
- |
575 |
- # Construct the $myeconfargs array by concatenating $our_conf |
576 |
- # (the common args) and $sapi_conf (the SAPI-specific args). |
577 |
- local myeconfargs=( "${our_conf[@]}" ) |
578 |
- myeconfargs+=( "${sapi_conf[@]}" ) |
579 |
- |
580 |
- pushd "${BUILD_DIR}" > /dev/null || die |
581 |
- econf "${myeconfargs[@]}" |
582 |
- popd > /dev/null || die |
583 |
- done |
584 |
-} |
585 |
- |
586 |
-src_compile() { |
587 |
- # snmp seems to run during src_compile, too (bug #324739) |
588 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
589 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
590 |
- |
591 |
- for sapi in ${SAPIS} ; do |
592 |
- if use "${sapi}"; then |
593 |
- cd "${WORKDIR}/sapis-build/$sapi" || \ |
594 |
- die "Failed to change dir to ${WORKDIR}/sapis-build/$1" |
595 |
- emake |
596 |
- fi |
597 |
- done |
598 |
-} |
599 |
- |
600 |
-src_install() { |
601 |
- # see bug #324739 for what happens when we don't have that |
602 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
603 |
- |
604 |
- # grab the first SAPI that got built and install common files from there |
605 |
- local first_sapi="" |
606 |
- for sapi in $SAPIS ; do |
607 |
- if use $sapi ; then |
608 |
- first_sapi=$sapi |
609 |
- break |
610 |
- fi |
611 |
- done |
612 |
- |
613 |
- # Makefile forgets to create this before trying to write to it... |
614 |
- dodir "${PHP_DESTDIR#${EPREFIX}}/bin" |
615 |
- |
616 |
- # Install php environment (without any sapis) |
617 |
- cd "${WORKDIR}/sapis-build/$first_sapi" || die |
618 |
- emake INSTALL_ROOT="${D}" \ |
619 |
- install-build install-headers install-programs |
620 |
- |
621 |
- local extension_dir="$("${ED}/${PHP_DESTDIR#${EPREFIX}}/bin/php-config" --extension-dir)" |
622 |
- |
623 |
- # Create the directory where we'll put version-specific php scripts |
624 |
- keepdir "/usr/share/php${PHP_MV}" |
625 |
- |
626 |
- local sapi="", file="" |
627 |
- local sapi_list="" |
628 |
- |
629 |
- for sapi in ${SAPIS}; do |
630 |
- if use "${sapi}" ; then |
631 |
- einfo "Installing SAPI: ${sapi}" |
632 |
- cd "${WORKDIR}/sapis-build/${sapi}" || die |
633 |
- |
634 |
- if [[ "${sapi}" == "apache2" ]] ; then |
635 |
- # We're specifically not using emake install-sapi as libtool |
636 |
- # may cause unnecessary relink failures (see bug #351266) |
637 |
- insinto "${PHP_DESTDIR#${EPREFIX}}/apache2/" |
638 |
- newins ".libs/libphp5$(get_libname)" \ |
639 |
- "libphp${PHP_MV}$(get_libname)" |
640 |
- keepdir "/usr/$(get_libdir)/apache2/modules" |
641 |
- else |
642 |
- # needed each time, php_install_ini would reset it |
643 |
- local dest="${PHP_DESTDIR#${EPREFIX}}" |
644 |
- into "${dest}" |
645 |
- case "$sapi" in |
646 |
- cli) |
647 |
- source="sapi/cli/php" |
648 |
- ;; |
649 |
- cgi) |
650 |
- source="sapi/cgi/php-cgi" |
651 |
- ;; |
652 |
- fpm) |
653 |
- source="sapi/fpm/php-fpm" |
654 |
- ;; |
655 |
- embed) |
656 |
- source="libs/libphp${PHP_MV}$(get_libname)" |
657 |
- ;; |
658 |
- *) |
659 |
- die "unhandled sapi in src_install" |
660 |
- ;; |
661 |
- esac |
662 |
- |
663 |
- if [[ "${source}" == *"$(get_libname)" ]]; then |
664 |
- dolib.so "${source}" |
665 |
- else |
666 |
- dobin "${source}" |
667 |
- local name="$(basename ${source})" |
668 |
- dosym "${dest}/bin/${name}" "/usr/bin/${name}${SLOT}" |
669 |
- fi |
670 |
- fi |
671 |
- |
672 |
- php_install_ini "${sapi}" |
673 |
- |
674 |
- # construct correct SAPI string for php-config |
675 |
- # thanks to ferringb for the bash voodoo |
676 |
- if [[ "${sapi}" == "apache2" ]]; then |
677 |
- sapi_list="${sapi_list:+${sapi_list} }apache2handler" |
678 |
- else |
679 |
- sapi_list="${sapi_list:+${sapi_list} }${sapi}" |
680 |
- fi |
681 |
- fi |
682 |
- done |
683 |
- |
684 |
- # Installing opcache module |
685 |
- if use opcache ; then |
686 |
- into "${PHP_DESTDIR#${EPREFIX}}" |
687 |
- dolib.so "modules/opcache$(get_libname)" |
688 |
- fi |
689 |
- |
690 |
- # Install env.d files |
691 |
- newenvd "${FILESDIR}/20php5-envd" "20php${SLOT}" |
692 |
- sed -e "s|/lib/|/$(get_libdir)/|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
693 |
- sed -e "s|php5|php${SLOT}|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
694 |
- |
695 |
- # set php-config variable correctly (bug #278439) |
696 |
- sed -e "s:^\(php_sapis=\)\".*\"$:\1\"${sapi_list}\":" -i \ |
697 |
- "${ED}/usr/$(get_libdir)/php${SLOT}/bin/php-config" || die |
698 |
- |
699 |
- if use fpm ; then |
700 |
- if use systemd; then |
701 |
- systemd_newunit "${FILESDIR}/php-fpm_at.service" \ |
702 |
- "php-fpm@${SLOT}.service" |
703 |
- else |
704 |
- systemd_newunit "${FILESDIR}/php-fpm_at-simple.service" \ |
705 |
- "php-fpm@${SLOT}.service" |
706 |
- fi |
707 |
- fi |
708 |
-} |
709 |
- |
710 |
-src_test() { |
711 |
- echo ">>> Test phase [test]: ${CATEGORY}/${PF}" |
712 |
- PHP_BIN="${WORKDIR}/sapis-build/cli/sapi/cli/php" |
713 |
- if [[ ! -x "${PHP_BIN}" ]] ; then |
714 |
- ewarn "Test phase requires USE=cli, skipping" |
715 |
- return |
716 |
- else |
717 |
- export TEST_PHP_EXECUTABLE="${PHP_BIN}" |
718 |
- fi |
719 |
- |
720 |
- if [[ -x "${WORKDIR}/sapis/cgi/php-cgi" ]] ; then |
721 |
- export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis/cgi/php-cgi" |
722 |
- fi |
723 |
- |
724 |
- REPORT_EXIT_STATUS=1 "${TEST_PHP_EXECUTABLE}" -n -d \ |
725 |
- "session.save_path=${T}" \ |
726 |
- "${WORKDIR}/sapis-build/cli/run-tests.php" -n -q -d \ |
727 |
- "session.save_path=${T}" |
728 |
- |
729 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
730 |
- mv "${name}.out" "${name}.out.orig" 2>/dev/null || die |
731 |
- done |
732 |
- |
733 |
- local failed="$(find -name '*.out')" |
734 |
- if [[ ${failed} != "" ]] ; then |
735 |
- ewarn "The following test cases failed unexpectedly:" |
736 |
- for name in ${failed}; do |
737 |
- ewarn " ${name/.out/}" |
738 |
- done |
739 |
- else |
740 |
- einfo "No unexpected test failures, all fine" |
741 |
- fi |
742 |
- |
743 |
- if [[ ${PHP_SHOW_UNEXPECTED_TEST_PASS} == "1" ]] ; then |
744 |
- local passed="" |
745 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
746 |
- [[ -f "${name}.diff" ]] && continue |
747 |
- passed="${passed} ${name}" |
748 |
- done |
749 |
- if [[ ${passed} != "" ]] ; then |
750 |
- einfo "The following test cases passed unexpectedly:" |
751 |
- for name in ${passed}; do |
752 |
- ewarn " ${passed}" |
753 |
- done |
754 |
- else |
755 |
- einfo "None of the known-to-fail tests passed, all fine" |
756 |
- fi |
757 |
- fi |
758 |
-} |
759 |
- |
760 |
-pkg_postinst() { |
761 |
- # Output some general info to the user |
762 |
- if use apache2 ; then |
763 |
- elog |
764 |
- elog "To enable PHP in apache, you will need to add \"-D PHP\" to" |
765 |
- elog "your apache2 command. OpenRC users can append that string to" |
766 |
- elog "APACHE2_OPTS in /etc/conf.d/apache2." |
767 |
- elog |
768 |
- elog "The apache module configuration file 70_mod_php.conf is" |
769 |
- elog "provided (and maintained) by eselect-php." |
770 |
- elog |
771 |
- fi |
772 |
- |
773 |
- # Create the symlinks for php |
774 |
- for m in ${SAPIS}; do |
775 |
- [[ ${m} == 'embed' ]] && continue; |
776 |
- if use $m ; then |
777 |
- local ci=$(eselect php show $m) |
778 |
- if [[ -z $ci ]]; then |
779 |
- eselect php set $m php${SLOT} || die |
780 |
- einfo "Switched ${m} to use php:${SLOT}" |
781 |
- einfo |
782 |
- elif [[ $ci != "php${SLOT}" ]] ; then |
783 |
- elog "To switch $m to use php:${SLOT}, run" |
784 |
- elog " eselect php set $m php${SLOT}" |
785 |
- elog |
786 |
- fi |
787 |
- fi |
788 |
- done |
789 |
- |
790 |
- # Remove dead symlinks for SAPIs that were just disabled. For |
791 |
- # example, if the user has the cgi SAPI enabled, then he has an |
792 |
- # eselect-php symlink for it. If he later reinstalls PHP with |
793 |
- # USE="-cgi", that symlink will break. This call to eselect is |
794 |
- # supposed to remove that dead link per bug 572436. |
795 |
- eselect php cleanup || die |
796 |
- |
797 |
- if ! has "php${SLOT/./-}" ${PHP_TARGETS}; then |
798 |
- elog "To build extensions for this version of PHP, you will need to" |
799 |
- elog "add php${SLOT/./-} to your PHP_TARGETS USE_EXPAND variable." |
800 |
- elog |
801 |
- fi |
802 |
- |
803 |
- # Warn about the removal of PHP_INI_VERSION if the user has it set. |
804 |
- if [[ -n "${PHP_INI_VERSION}" ]]; then |
805 |
- ewarn 'The PHP_INI_VERSION variable has been phased out. You may' |
806 |
- ewarn 'remove it from your configuration at your convenience. See' |
807 |
- ewarn |
808 |
- ewarn ' https://bugs.gentoo.org/611214' |
809 |
- ewarn |
810 |
- ewarn 'for more information.' |
811 |
- fi |
812 |
- |
813 |
- elog "For details on how version slotting works, please see" |
814 |
- elog "the wiki:" |
815 |
- elog |
816 |
- elog " https://wiki.gentoo.org/wiki/PHP" |
817 |
- elog |
818 |
-} |
819 |
- |
820 |
-pkg_postrm() { |
821 |
- # This serves two purposes. First, if we have just removed the last |
822 |
- # installed version of PHP, then this will remove any dead symlinks |
823 |
- # belonging to eselect-php. Second, if a user upgrades slots from |
824 |
- # (say) 5.6 to 7.0 and depcleans the old slot, then this will update |
825 |
- # his existing symlinks to point to the new 7.0 installation. The |
826 |
- # latter is bug 432962. |
827 |
- # |
828 |
- # Note: the eselect-php package may not be installed at this point, |
829 |
- # so we can't die() if this command fails. |
830 |
- eselect php cleanup |
831 |
-} |
832 |
|
833 |
diff --git a/dev-lang/php/php-7.1.30.ebuild b/dev-lang/php/php-7.1.30.ebuild |
834 |
deleted file mode 100644 |
835 |
index 3be3c028962..00000000000 |
836 |
--- a/dev-lang/php/php-7.1.30.ebuild |
837 |
+++ /dev/null |
838 |
@@ -1,737 +0,0 @@ |
839 |
-# Copyright 1999-2019 Gentoo Authors |
840 |
-# Distributed under the terms of the GNU General Public License v2 |
841 |
- |
842 |
-EAPI="7" |
843 |
- |
844 |
-inherit flag-o-matic systemd autotools |
845 |
- |
846 |
-DESCRIPTION="The PHP language runtime engine" |
847 |
-HOMEPAGE="https://php.net/" |
848 |
-SRC_URI="https://php.net/distributions/${P}.tar.xz" |
849 |
- |
850 |
-LICENSE="PHP-3.01 |
851 |
- BSD |
852 |
- Zend-2.0 |
853 |
- bcmath? ( LGPL-2.1+ ) |
854 |
- fpm? ( BSD-2 ) |
855 |
- gd? ( gd ) |
856 |
- unicode? ( BSD-2 LGPL-2.1 )" |
857 |
- |
858 |
-SLOT="$(ver_cut 1-2)" |
859 |
-KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos" |
860 |
- |
861 |
-# We can build the following SAPIs in the given order |
862 |
-SAPIS="embed cli cgi fpm apache2 phpdbg" |
863 |
- |
864 |
-# SAPIs and SAPI-specific USE flags (cli SAPI is default on): |
865 |
-IUSE="${IUSE} |
866 |
- ${SAPIS/cli/+cli} |
867 |
- threads" |
868 |
- |
869 |
-IUSE="${IUSE} acl bcmath berkdb bzip2 calendar cdb cjk |
870 |
- coverage crypt +ctype curl debug |
871 |
- enchant exif +fileinfo +filter firebird |
872 |
- flatfile ftp gd gdbm gmp +hash +iconv imap inifile |
873 |
- intl iodbc ipv6 +json kerberos ldap ldap-sasl libedit libressl |
874 |
- mhash mssql mysql mysqli nls |
875 |
- oci8-instant-client odbc +opcache pcntl pdo +phar +posix postgres qdbm |
876 |
- readline recode selinux +session session-mm sharedmem |
877 |
- +simplexml snmp soap sockets spell sqlite ssl |
878 |
- sysvipc systemd test tidy +tokenizer truetype unicode wddx webp |
879 |
- +xml xmlreader xmlwriter xmlrpc xpm xslt zip zlib" |
880 |
- |
881 |
-# The supported (that is, autodetected) versions of BDB are listed in |
882 |
-# the ./configure script. Other versions *work*, but we need to stick to |
883 |
-# the ones that can be detected to avoid a repeat of bug #564824. |
884 |
-COMMON_DEPEND=" |
885 |
- >=app-eselect/eselect-php-0.9.1[apache2?,fpm?] |
886 |
- >=dev-libs/libpcre-8.32[unicode] |
887 |
- fpm? ( acl? ( sys-apps/acl ) ) |
888 |
- apache2? ( || ( >=www-servers/apache-2.4[apache2_modules_unixd,threads=] |
889 |
- <www-servers/apache-2.4[threads=] ) ) |
890 |
- berkdb? ( || ( sys-libs/db:5.3 |
891 |
- sys-libs/db:5.1 |
892 |
- sys-libs/db:4.8 |
893 |
- sys-libs/db:4.7 |
894 |
- sys-libs/db:4.6 |
895 |
- sys-libs/db:4.5 ) ) |
896 |
- bzip2? ( app-arch/bzip2:0= ) |
897 |
- cdb? ( || ( dev-db/cdb dev-db/tinycdb ) ) |
898 |
- coverage? ( dev-util/lcov ) |
899 |
- crypt? ( >=dev-libs/libmcrypt-2.4 ) |
900 |
- curl? ( >=net-misc/curl-7.10.5 ) |
901 |
- enchant? ( <app-text/enchant-2.0:0 ) |
902 |
- firebird? ( dev-db/firebird ) |
903 |
- gd? ( virtual/jpeg:0 media-libs/libpng:0= sys-libs/zlib ) |
904 |
- gdbm? ( >=sys-libs/gdbm-1.8.0:0= ) |
905 |
- gmp? ( dev-libs/gmp:0= ) |
906 |
- iconv? ( virtual/libiconv ) |
907 |
- imap? ( virtual/imap-c-client[kerberos=,ssl=] ) |
908 |
- intl? ( dev-libs/icu:= ) |
909 |
- iodbc? ( dev-db/libiodbc ) |
910 |
- kerberos? ( virtual/krb5 ) |
911 |
- ldap? ( >=net-nds/openldap-1.2.11 ) |
912 |
- ldap-sasl? ( dev-libs/cyrus-sasl >=net-nds/openldap-1.2.11 ) |
913 |
- libedit? ( || ( sys-freebsd/freebsd-lib dev-libs/libedit ) ) |
914 |
- mssql? ( dev-db/freetds[mssql] ) |
915 |
- nls? ( sys-devel/gettext ) |
916 |
- oci8-instant-client? ( dev-db/oracle-instantclient-basic ) |
917 |
- odbc? ( >=dev-db/unixODBC-1.8.13 ) |
918 |
- postgres? ( dev-db/postgresql:* ) |
919 |
- qdbm? ( dev-db/qdbm ) |
920 |
- readline? ( sys-libs/readline:0= ) |
921 |
- recode? ( app-text/recode ) |
922 |
- session-mm? ( dev-libs/mm ) |
923 |
- simplexml? ( >=dev-libs/libxml2-2.6.8 ) |
924 |
- snmp? ( >=net-analyzer/net-snmp-5.2 ) |
925 |
- soap? ( >=dev-libs/libxml2-2.6.8 ) |
926 |
- spell? ( >=app-text/aspell-0.50 ) |
927 |
- sqlite? ( >=dev-db/sqlite-3.7.6.3 ) |
928 |
- ssl? ( |
929 |
- !libressl? ( dev-libs/openssl:0= ) |
930 |
- libressl? ( dev-libs/libressl:0= ) |
931 |
- ) |
932 |
- tidy? ( || ( app-text/tidy-html5 app-text/htmltidy ) ) |
933 |
- truetype? ( =media-libs/freetype-2* ) |
934 |
- unicode? ( dev-libs/oniguruma:= ) |
935 |
- wddx? ( >=dev-libs/libxml2-2.6.8 ) |
936 |
- webp? ( media-libs/libwebp:0= ) |
937 |
- xml? ( >=dev-libs/libxml2-2.6.8 ) |
938 |
- xmlrpc? ( >=dev-libs/libxml2-2.6.8 virtual/libiconv ) |
939 |
- xmlreader? ( >=dev-libs/libxml2-2.6.8 ) |
940 |
- xmlwriter? ( >=dev-libs/libxml2-2.6.8 ) |
941 |
- xpm? ( x11-libs/libXpm ) |
942 |
- xslt? ( dev-libs/libxslt >=dev-libs/libxml2-2.6.8 ) |
943 |
- zip? ( sys-libs/zlib:0= ) |
944 |
- zlib? ( sys-libs/zlib:0= ) |
945 |
-" |
946 |
- |
947 |
-RDEPEND="${COMMON_DEPEND} |
948 |
- virtual/mta |
949 |
- fpm? ( |
950 |
- selinux? ( sec-policy/selinux-phpfpm ) |
951 |
- systemd? ( sys-apps/systemd ) )" |
952 |
- |
953 |
-# Bison isn't actually needed when building from a release tarball |
954 |
-# However, the configure script will warn if it's absent or if you |
955 |
-# have an incompatible version installed. See bug 593278. |
956 |
-DEPEND="${COMMON_DEPEND} |
957 |
- app-arch/xz-utils |
958 |
- >=sys-devel/bison-3.0.1" |
959 |
- |
960 |
-BDEPEND="virtual/pkgconfig" |
961 |
- |
962 |
-# Without USE=readline or libedit, the interactive "php -a" CLI will hang. |
963 |
-REQUIRED_USE=" |
964 |
- || ( cli cgi fpm apache2 embed phpdbg ) |
965 |
- cli? ( ^^ ( readline libedit ) ) |
966 |
- truetype? ( gd zlib ) |
967 |
- webp? ( gd zlib ) |
968 |
- cjk? ( gd zlib ) |
969 |
- exif? ( gd zlib ) |
970 |
- xpm? ( gd zlib ) |
971 |
- gd? ( zlib ) |
972 |
- simplexml? ( xml ) |
973 |
- soap? ( xml ) |
974 |
- wddx? ( xml ) |
975 |
- xmlrpc? ( || ( xml iconv ) ) |
976 |
- xmlreader? ( xml ) |
977 |
- xslt? ( xml ) |
978 |
- ldap-sasl? ( ldap ) |
979 |
- mhash? ( hash ) |
980 |
- phar? ( hash ) |
981 |
- qdbm? ( !gdbm ) |
982 |
- readline? ( !libedit ) |
983 |
- recode? ( !imap !mysqli !mysql ) |
984 |
- session-mm? ( session !threads ) |
985 |
- mysql? ( hash || ( mysqli pdo ) ) |
986 |
- mysqli? ( hash ) |
987 |
-" |
988 |
-PATCHES=( |
989 |
- "${FILESDIR}/php-freetype-2.9.1.patch" |
990 |
- "${FILESDIR}/php-7.1.25-intl-use-icu-namespace.patch" |
991 |
-) |
992 |
- |
993 |
-PHP_MV="$(ver_cut 1)" |
994 |
- |
995 |
-php_install_ini() { |
996 |
- local phpsapi="${1}" |
997 |
- |
998 |
- # work out where we are installing the ini file |
999 |
- php_set_ini_dir "${phpsapi}" |
1000 |
- |
1001 |
- # Always install the production INI file, bug 611214. |
1002 |
- local phpinisrc="php.ini-production-${phpsapi}" |
1003 |
- cp php.ini-production "${phpinisrc}" || die |
1004 |
- |
1005 |
- # default to /tmp for save_path, bug #282768 |
1006 |
- sed -e 's|^;session.save_path .*$|session.save_path = "'"${EPREFIX}"'/tmp"|g' -i "${phpinisrc}" || die |
1007 |
- |
1008 |
- # Set the extension dir |
1009 |
- sed -e "s|^extension_dir .*$|extension_dir = ${extension_dir}|g" \ |
1010 |
- -i "${phpinisrc}" || die |
1011 |
- |
1012 |
- # Set the include path to point to where we want to find PEAR packages |
1013 |
- sed -e 's|^;include_path = ".:/php/includes".*|include_path = ".:'"${EPREFIX}"'/usr/share/php'${PHP_MV}':'"${EPREFIX}"'/usr/share/php"|' -i "${phpinisrc}" || die |
1014 |
- |
1015 |
- dodir "${PHP_INI_DIR#${EPREFIX}}" |
1016 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
1017 |
- newins "${phpinisrc}" php.ini |
1018 |
- |
1019 |
- elog "Installing php.ini for ${phpsapi} into ${PHP_INI_DIR#${EPREFIX}}" |
1020 |
- elog |
1021 |
- |
1022 |
- dodir "${PHP_EXT_INI_DIR#${EPREFIX}}" |
1023 |
- dodir "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}" |
1024 |
- |
1025 |
- if use opcache; then |
1026 |
- elog "Adding opcache to $PHP_EXT_INI_DIR" |
1027 |
- echo "zend_extension=${PHP_DESTDIR}/$(get_libdir)/opcache.so" >> \ |
1028 |
- "${D}/${PHP_EXT_INI_DIR}"/opcache.ini |
1029 |
- dosym "${PHP_EXT_INI_DIR#${EPREFIX}}/opcache.ini" \ |
1030 |
- "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}/opcache.ini" |
1031 |
- fi |
1032 |
- |
1033 |
- # SAPI-specific handling |
1034 |
- if [[ "${sapi}" == "fpm" ]] ; then |
1035 |
- einfo "Installing FPM config files php-fpm.conf and www.conf" |
1036 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
1037 |
- doins sapi/fpm/php-fpm.conf |
1038 |
- insinto "${PHP_INI_DIR#${EPREFIX}}/fpm.d" |
1039 |
- doins sapi/fpm/www.conf |
1040 |
- fi |
1041 |
- |
1042 |
- dodoc php.ini-{development,production} |
1043 |
-} |
1044 |
- |
1045 |
-php_set_ini_dir() { |
1046 |
- PHP_INI_DIR="${EPREFIX}/etc/php/${1}-php${SLOT}" |
1047 |
- PHP_EXT_INI_DIR="${PHP_INI_DIR}/ext" |
1048 |
- PHP_EXT_INI_DIR_ACTIVE="${PHP_INI_DIR}/ext-active" |
1049 |
-} |
1050 |
- |
1051 |
-src_prepare() { |
1052 |
- default |
1053 |
- |
1054 |
- # In php-7.x, the FPM pool configuration files have been split off |
1055 |
- # of the main config. By default the pool config files go in |
1056 |
- # e.g. /etc/php-fpm.d, which isn't slotted. So here we move the |
1057 |
- # include directory to a subdirectory "fpm.d" of $PHP_INI_DIR. Later |
1058 |
- # we'll install the pool configuration file "www.conf" there. |
1059 |
- php_set_ini_dir fpm |
1060 |
- sed -i "s~^include=.*$~include=${PHP_INI_DIR}/fpm.d/*.conf~" \ |
1061 |
- sapi/fpm/php-fpm.conf.in \ |
1062 |
- || die 'failed to move the include directory in php-fpm.conf' |
1063 |
- |
1064 |
- # Bug 669566 - necessary so that build tools are updated for commands like pecl |
1065 |
- # Force rebuilding aclocal.m4 |
1066 |
- rm -f aclocal.m4 || die "failed to remove aclocal.m4 in src_prepare" |
1067 |
- eautoreconf |
1068 |
-} |
1069 |
- |
1070 |
-src_configure() { |
1071 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
1072 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
1073 |
- |
1074 |
- PHP_DESTDIR="${EPREFIX}/usr/$(get_libdir)/php${SLOT}" |
1075 |
- |
1076 |
- # The php-fpm config file wants localstatedir to be ${EPREFIX}/var |
1077 |
- # and not the Gentoo default ${EPREFIX}/var/lib. See bug 572002. |
1078 |
- local our_conf=( |
1079 |
- --prefix="${PHP_DESTDIR}" |
1080 |
- --mandir="${PHP_DESTDIR}/man" |
1081 |
- --infodir="${PHP_DESTDIR}/info" |
1082 |
- --libdir="${PHP_DESTDIR}/lib" |
1083 |
- --with-libdir="$(get_libdir)" |
1084 |
- --localstatedir="${EPREFIX}/var" |
1085 |
- --without-pear |
1086 |
- $(use_enable threads maintainer-zts) |
1087 |
- ) |
1088 |
- |
1089 |
- our_conf+=( |
1090 |
- $(use_enable bcmath bcmath) |
1091 |
- $(use_with bzip2 bz2 "${EPREFIX}/usr") |
1092 |
- $(use_enable calendar calendar) |
1093 |
- $(use_enable coverage gcov) |
1094 |
- $(use_enable ctype ctype) |
1095 |
- $(use_with curl curl "${EPREFIX}/usr") |
1096 |
- $(use_enable xml dom) |
1097 |
- $(use_with enchant enchant "${EPREFIX}/usr") |
1098 |
- $(use_enable exif exif) |
1099 |
- $(use_enable fileinfo fileinfo) |
1100 |
- $(use_enable filter filter) |
1101 |
- $(use_enable ftp ftp) |
1102 |
- $(use_with nls gettext "${EPREFIX}/usr") |
1103 |
- $(use_with gmp gmp "${EPREFIX}/usr") |
1104 |
- $(use_enable hash hash) |
1105 |
- $(use_with mhash mhash "${EPREFIX}/usr") |
1106 |
- $(use_with iconv iconv \ |
1107 |
- $(use elibc_glibc || use elibc_musl || use elibc_FreeBSD || echo "${EPREFIX}/usr")) |
1108 |
- $(use_enable intl intl) |
1109 |
- $(use_enable ipv6 ipv6) |
1110 |
- $(use_enable json json) |
1111 |
- $(use_with kerberos kerberos "${EPREFIX}/usr") |
1112 |
- $(use_enable xml libxml) |
1113 |
- $(use_with xml libxml-dir "${EPREFIX}/usr") |
1114 |
- $(use_enable unicode mbstring) |
1115 |
- $(use_with crypt mcrypt "${EPREFIX}/usr") |
1116 |
- $(use_with unicode onig "${EPREFIX}/usr") |
1117 |
- $(use_with ssl openssl "${EPREFIX}/usr") |
1118 |
- $(use_with ssl openssl-dir "${EPREFIX}/usr") |
1119 |
- $(use_enable pcntl pcntl) |
1120 |
- $(use_enable phar phar) |
1121 |
- $(use_enable pdo pdo) |
1122 |
- $(use_enable opcache opcache) |
1123 |
- $(use_with postgres pgsql "${EPREFIX}/usr") |
1124 |
- $(use_enable posix posix) |
1125 |
- $(use_with spell pspell "${EPREFIX}/usr") |
1126 |
- $(use_with recode recode "${EPREFIX}/usr") |
1127 |
- $(use_enable simplexml simplexml) |
1128 |
- $(use_enable sharedmem shmop) |
1129 |
- $(use_with snmp snmp "${EPREFIX}/usr") |
1130 |
- $(use_enable soap soap) |
1131 |
- $(use_enable sockets sockets) |
1132 |
- $(use_with sqlite sqlite3 "${EPREFIX}/usr") |
1133 |
- $(use_enable sysvipc sysvmsg) |
1134 |
- $(use_enable sysvipc sysvsem) |
1135 |
- $(use_enable sysvipc sysvshm) |
1136 |
- $(use_with tidy tidy "${EPREFIX}/usr") |
1137 |
- $(use_enable tokenizer tokenizer) |
1138 |
- $(use_enable wddx wddx) |
1139 |
- $(use_enable xml xml) |
1140 |
- $(use_enable xmlreader xmlreader) |
1141 |
- $(use_enable xmlwriter xmlwriter) |
1142 |
- $(use_with xmlrpc xmlrpc) |
1143 |
- $(use_with xslt xsl "${EPREFIX}/usr") |
1144 |
- $(use_enable zip zip) |
1145 |
- $(use_with zlib zlib "${EPREFIX}/usr") |
1146 |
- $(use_enable debug debug) |
1147 |
- ) |
1148 |
- |
1149 |
- # DBA support |
1150 |
- if use cdb || use berkdb || use flatfile || use gdbm || use inifile \ |
1151 |
- || use qdbm ; then |
1152 |
- our_conf+=( "--enable-dba${shared}" ) |
1153 |
- fi |
1154 |
- |
1155 |
- # DBA drivers support |
1156 |
- our_conf+=( |
1157 |
- $(use_with cdb cdb) |
1158 |
- $(use_with berkdb db4 "${EPREFIX}/usr") |
1159 |
- $(use_enable flatfile flatfile) |
1160 |
- $(use_with gdbm gdbm "${EPREFIX}/usr") |
1161 |
- $(use_enable inifile inifile) |
1162 |
- $(use_with qdbm qdbm "${EPREFIX}/usr") |
1163 |
- ) |
1164 |
- |
1165 |
- # Support for the GD graphics library |
1166 |
- our_conf+=( |
1167 |
- $(use_with truetype freetype-dir "${EPREFIX}/usr") |
1168 |
- $(use_enable cjk gd-jis-conv) |
1169 |
- $(use_with gd jpeg-dir "${EPREFIX}/usr") |
1170 |
- $(use_with gd png-dir "${EPREFIX}/usr") |
1171 |
- $(use_with xpm xpm-dir "${EPREFIX}/usr") |
1172 |
- ) |
1173 |
- if use webp; then |
1174 |
- our_conf+=( --with-webp-dir="${EPREFIX}/usr" ) |
1175 |
- fi |
1176 |
- # enable gd last, so configure can pick up the previous settings |
1177 |
- our_conf+=( $(use_with gd gd) ) |
1178 |
- |
1179 |
- # IMAP support |
1180 |
- if use imap ; then |
1181 |
- our_conf+=( |
1182 |
- $(use_with imap imap "${EPREFIX}/usr") |
1183 |
- $(use_with ssl imap-ssl "${EPREFIX}/usr") |
1184 |
- ) |
1185 |
- fi |
1186 |
- |
1187 |
- # Interbase/firebird support |
1188 |
- our_conf+=( $(use_with firebird interbase "${EPREFIX}/usr") ) |
1189 |
- |
1190 |
- # LDAP support |
1191 |
- if use ldap ; then |
1192 |
- our_conf+=( |
1193 |
- $(use_with ldap ldap "${EPREFIX}/usr") |
1194 |
- $(use_with ldap-sasl ldap-sasl "${EPREFIX}/usr") |
1195 |
- ) |
1196 |
- fi |
1197 |
- |
1198 |
- # MySQL support |
1199 |
- local mysqllib="mysqlnd" |
1200 |
- local mysqlilib="mysqlnd" |
1201 |
- |
1202 |
- our_conf+=( $(use_with mysqli mysqli "${mysqlilib}") ) |
1203 |
- |
1204 |
- local mysqlsock="${EPREFIX}/var/run/mysqld/mysqld.sock" |
1205 |
- if use mysql || use mysqli ; then |
1206 |
- our_conf+=( $(use_with mysql mysql-sock "${mysqlsock}") ) |
1207 |
- fi |
1208 |
- |
1209 |
- # ODBC support |
1210 |
- our_conf+=( |
1211 |
- $(use_with odbc unixODBC "${EPREFIX}/usr") |
1212 |
- $(use_with iodbc iodbc "${EPREFIX}/usr") |
1213 |
- ) |
1214 |
- |
1215 |
- # Oracle support |
1216 |
- our_conf+=( $(use_with oci8-instant-client oci8) ) |
1217 |
- |
1218 |
- # PDO support |
1219 |
- if use pdo ; then |
1220 |
- our_conf+=( |
1221 |
- $(use_with mssql pdo-dblib "${EPREFIX}/usr") |
1222 |
- $(use_with mysql pdo-mysql "${mysqllib}") |
1223 |
- $(use_with postgres pdo-pgsql) |
1224 |
- $(use_with sqlite pdo-sqlite "${EPREFIX}/usr") |
1225 |
- $(use_with firebird pdo-firebird "${EPREFIX}/usr") |
1226 |
- $(use_with odbc pdo-odbc "unixODBC,${EPREFIX}/usr") |
1227 |
- $(use_with oci8-instant-client pdo-oci) |
1228 |
- ) |
1229 |
- fi |
1230 |
- |
1231 |
- # readline/libedit support |
1232 |
- our_conf+=( |
1233 |
- $(use_with readline readline "${EPREFIX}/usr") |
1234 |
- $(use_with libedit libedit "${EPREFIX}/usr") |
1235 |
- ) |
1236 |
- |
1237 |
- # Session support |
1238 |
- if use session ; then |
1239 |
- our_conf+=( $(use_with session-mm mm "${EPREFIX}/usr") ) |
1240 |
- else |
1241 |
- our_conf+=( $(use_enable session session) ) |
1242 |
- fi |
1243 |
- |
1244 |
- # Use pic for shared modules such as apache2's mod_php |
1245 |
- our_conf+=( --with-pic ) |
1246 |
- |
1247 |
- # we use the system copy of pcre |
1248 |
- # --with-pcre-regex affects ext/pcre |
1249 |
- # --with-pcre-dir affects ext/filter and ext/zip |
1250 |
- our_conf+=( |
1251 |
- --with-pcre-regex="${EPREFIX}/usr" |
1252 |
- --with-pcre-dir="${EPREFIX}/usr" |
1253 |
- ) |
1254 |
- |
1255 |
- # Catch CFLAGS problems |
1256 |
- # Fixes bug #14067. |
1257 |
- # Changed order to run it in reverse for bug #32022 and #12021. |
1258 |
- replace-cpu-flags "k6*" "i586" |
1259 |
- |
1260 |
- # Cache the ./configure test results between SAPIs. |
1261 |
- our_conf+=( --cache-file="${T}/config.cache" ) |
1262 |
- |
1263 |
- # Support user-passed configuration parameters |
1264 |
- our_conf+=( ${EXTRA_ECONF:-} ) |
1265 |
- |
1266 |
- # Support the Apache2 extras, they must be set globally for all |
1267 |
- # SAPIs to work correctly, especially for external PHP extensions |
1268 |
- |
1269 |
- mkdir -p "${WORKDIR}/sapis-build" || die |
1270 |
- for one_sapi in $SAPIS ; do |
1271 |
- use "${one_sapi}" || continue |
1272 |
- php_set_ini_dir "${one_sapi}" |
1273 |
- |
1274 |
- # The BUILD_DIR variable is used to determine where to output |
1275 |
- # the files that autotools creates. This was all originally |
1276 |
- # based on the autotools-utils eclass. |
1277 |
- BUILD_DIR="${WORKDIR}/sapis-build/${one_sapi}" |
1278 |
- cp -a "${S}" "${BUILD_DIR}" || die |
1279 |
- cd "${BUILD_DIR}" || die |
1280 |
- |
1281 |
- local sapi_conf=( |
1282 |
- --with-config-file-path="${PHP_INI_DIR}" |
1283 |
- --with-config-file-scan-dir="${PHP_EXT_INI_DIR_ACTIVE}" |
1284 |
- ) |
1285 |
- |
1286 |
- for sapi in $SAPIS ; do |
1287 |
- case "$sapi" in |
1288 |
- cli|cgi|embed|fpm|phpdbg) |
1289 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
1290 |
- sapi_conf+=( "--enable-${sapi}" ) |
1291 |
- if [[ "fpm" == "${sapi}" ]] ; then |
1292 |
- sapi_conf+=( |
1293 |
- $(use_with acl fpm-acl) |
1294 |
- $(use_with systemd fpm-systemd) |
1295 |
- ) |
1296 |
- fi |
1297 |
- else |
1298 |
- sapi_conf+=( "--disable-${sapi}" ) |
1299 |
- fi |
1300 |
- ;; |
1301 |
- |
1302 |
- apache2) |
1303 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
1304 |
- sapi_conf+=( --with-apxs2="${EPREFIX}/usr/bin/apxs" ) |
1305 |
- else |
1306 |
- sapi_conf+=( --without-apxs2 ) |
1307 |
- fi |
1308 |
- ;; |
1309 |
- esac |
1310 |
- done |
1311 |
- |
1312 |
- # Construct the $myeconfargs array by concatenating $our_conf |
1313 |
- # (the common args) and $sapi_conf (the SAPI-specific args). |
1314 |
- local myeconfargs=( "${our_conf[@]}" ) |
1315 |
- myeconfargs+=( "${sapi_conf[@]}" ) |
1316 |
- |
1317 |
- pushd "${BUILD_DIR}" > /dev/null || die |
1318 |
- econf "${myeconfargs[@]}" |
1319 |
- popd > /dev/null || die |
1320 |
- done |
1321 |
-} |
1322 |
- |
1323 |
-src_compile() { |
1324 |
- # snmp seems to run during src_compile, too (bug #324739) |
1325 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
1326 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
1327 |
- |
1328 |
- for sapi in ${SAPIS} ; do |
1329 |
- if use "${sapi}"; then |
1330 |
- cd "${WORKDIR}/sapis-build/$sapi" || \ |
1331 |
- die "Failed to change dir to ${WORKDIR}/sapis-build/$1" |
1332 |
- emake |
1333 |
- fi |
1334 |
- done |
1335 |
-} |
1336 |
- |
1337 |
-src_install() { |
1338 |
- # see bug #324739 for what happens when we don't have that |
1339 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
1340 |
- |
1341 |
- # grab the first SAPI that got built and install common files from there |
1342 |
- local first_sapi="" |
1343 |
- for sapi in $SAPIS ; do |
1344 |
- if use $sapi ; then |
1345 |
- first_sapi=$sapi |
1346 |
- break |
1347 |
- fi |
1348 |
- done |
1349 |
- |
1350 |
- # Makefile forgets to create this before trying to write to it... |
1351 |
- dodir "${PHP_DESTDIR#${EPREFIX}}/bin" |
1352 |
- |
1353 |
- # Install php environment (without any sapis) |
1354 |
- cd "${WORKDIR}/sapis-build/$first_sapi" || die |
1355 |
- emake INSTALL_ROOT="${D}" \ |
1356 |
- install-build install-headers install-programs |
1357 |
- |
1358 |
- local extension_dir="$("${ED}/${PHP_DESTDIR#${EPREFIX}}/bin/php-config" --extension-dir)" |
1359 |
- |
1360 |
- # Create the directory where we'll put version-specific php scripts |
1361 |
- keepdir "/usr/share/php${PHP_MV}" |
1362 |
- |
1363 |
- local sapi="", file="" |
1364 |
- local sapi_list="" |
1365 |
- |
1366 |
- for sapi in ${SAPIS}; do |
1367 |
- if use "${sapi}" ; then |
1368 |
- einfo "Installing SAPI: ${sapi}" |
1369 |
- cd "${WORKDIR}/sapis-build/${sapi}" || die |
1370 |
- |
1371 |
- if [[ "${sapi}" == "apache2" ]] ; then |
1372 |
- # We're specifically not using emake install-sapi as libtool |
1373 |
- # may cause unnecessary relink failures (see bug #351266) |
1374 |
- insinto "${PHP_DESTDIR#${EPREFIX}}/apache2/" |
1375 |
- newins ".libs/libphp${PHP_MV}$(get_libname)" \ |
1376 |
- "libphp${PHP_MV}$(get_libname)" |
1377 |
- keepdir "/usr/$(get_libdir)/apache2/modules" |
1378 |
- else |
1379 |
- # needed each time, php_install_ini would reset it |
1380 |
- local dest="${PHP_DESTDIR#${EPREFIX}}" |
1381 |
- into "${dest}" |
1382 |
- case "$sapi" in |
1383 |
- cli) |
1384 |
- source="sapi/cli/php" |
1385 |
- ;; |
1386 |
- cgi) |
1387 |
- source="sapi/cgi/php-cgi" |
1388 |
- ;; |
1389 |
- fpm) |
1390 |
- source="sapi/fpm/php-fpm" |
1391 |
- ;; |
1392 |
- embed) |
1393 |
- source="libs/libphp${PHP_MV}$(get_libname)" |
1394 |
- ;; |
1395 |
- phpdbg) |
1396 |
- source="sapi/phpdbg/phpdbg" |
1397 |
- ;; |
1398 |
- *) |
1399 |
- die "unhandled sapi in src_install" |
1400 |
- ;; |
1401 |
- esac |
1402 |
- |
1403 |
- if [[ "${source}" == *"$(get_libname)" ]]; then |
1404 |
- dolib.so "${source}" |
1405 |
- else |
1406 |
- dobin "${source}" |
1407 |
- local name="$(basename ${source})" |
1408 |
- dosym "${dest}/bin/${name}" "/usr/bin/${name}${SLOT}" |
1409 |
- fi |
1410 |
- fi |
1411 |
- |
1412 |
- php_install_ini "${sapi}" |
1413 |
- |
1414 |
- # construct correct SAPI string for php-config |
1415 |
- # thanks to ferringb for the bash voodoo |
1416 |
- if [[ "${sapi}" == "apache2" ]]; then |
1417 |
- sapi_list="${sapi_list:+${sapi_list} }apache2handler" |
1418 |
- else |
1419 |
- sapi_list="${sapi_list:+${sapi_list} }${sapi}" |
1420 |
- fi |
1421 |
- fi |
1422 |
- done |
1423 |
- |
1424 |
- # Installing opcache module |
1425 |
- if use opcache ; then |
1426 |
- into "${PHP_DESTDIR#${EPREFIX}}" |
1427 |
- dolib.so "modules/opcache$(get_libname)" |
1428 |
- fi |
1429 |
- |
1430 |
- # Install env.d files |
1431 |
- newenvd "${FILESDIR}/20php5-envd" "20php${SLOT}" |
1432 |
- sed -e "s|/lib/|/$(get_libdir)/|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
1433 |
- sed -e "s|php5|php${SLOT}|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
1434 |
- |
1435 |
- # set php-config variable correctly (bug #278439) |
1436 |
- sed -e "s:^\(php_sapis=\)\".*\"$:\1\"${sapi_list}\":" -i \ |
1437 |
- "${ED}/usr/$(get_libdir)/php${SLOT}/bin/php-config" || die |
1438 |
- |
1439 |
- if use fpm ; then |
1440 |
- if use systemd; then |
1441 |
- systemd_newunit "${FILESDIR}/php-fpm_at.service" \ |
1442 |
- "php-fpm@${SLOT}.service" |
1443 |
- else |
1444 |
- systemd_newunit "${FILESDIR}/php-fpm_at-simple.service" \ |
1445 |
- "php-fpm@${SLOT}.service" |
1446 |
- fi |
1447 |
- fi |
1448 |
-} |
1449 |
- |
1450 |
-src_test() { |
1451 |
- echo ">>> Test phase [test]: ${CATEGORY}/${PF}" |
1452 |
- PHP_BIN="${WORKDIR}/sapis-build/cli/sapi/cli/php" |
1453 |
- if [[ ! -x "${PHP_BIN}" ]] ; then |
1454 |
- ewarn "Test phase requires USE=cli, skipping" |
1455 |
- return |
1456 |
- else |
1457 |
- export TEST_PHP_EXECUTABLE="${PHP_BIN}" |
1458 |
- fi |
1459 |
- |
1460 |
- if [[ -x "${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi" ]] ; then |
1461 |
- export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi" |
1462 |
- fi |
1463 |
- |
1464 |
- if [[ -x "${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" ]] ; then |
1465 |
- export TEST_PHPDBG_EXECUTABLE="${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" |
1466 |
- fi |
1467 |
- |
1468 |
- REPORT_EXIT_STATUS=1 "${TEST_PHP_EXECUTABLE}" -n -d \ |
1469 |
- "session.save_path=${T}" \ |
1470 |
- "${WORKDIR}/sapis-build/cli/run-tests.php" -n -q -d \ |
1471 |
- "session.save_path=${T}" |
1472 |
- |
1473 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
1474 |
- mv "${name}.out" "${name}.out.orig" 2>/dev/null || die |
1475 |
- done |
1476 |
- |
1477 |
- local failed="$(find -name '*.out')" |
1478 |
- if [[ ${failed} != "" ]] ; then |
1479 |
- ewarn "The following test cases failed unexpectedly:" |
1480 |
- for name in ${failed}; do |
1481 |
- ewarn " ${name/.out/}" |
1482 |
- done |
1483 |
- else |
1484 |
- einfo "No unexpected test failures, all fine" |
1485 |
- fi |
1486 |
- |
1487 |
- if [[ ${PHP_SHOW_UNEXPECTED_TEST_PASS} == "1" ]] ; then |
1488 |
- local passed="" |
1489 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
1490 |
- [[ -f "${name}.diff" ]] && continue |
1491 |
- passed="${passed} ${name}" |
1492 |
- done |
1493 |
- if [[ ${passed} != "" ]] ; then |
1494 |
- einfo "The following test cases passed unexpectedly:" |
1495 |
- for name in ${passed}; do |
1496 |
- ewarn " ${passed}" |
1497 |
- done |
1498 |
- else |
1499 |
- einfo "None of the known-to-fail tests passed, all fine" |
1500 |
- fi |
1501 |
- fi |
1502 |
-} |
1503 |
- |
1504 |
-pkg_postinst() { |
1505 |
- # Output some general info to the user |
1506 |
- if use apache2 ; then |
1507 |
- elog |
1508 |
- elog "To enable PHP in apache, you will need to add \"-D PHP\" to" |
1509 |
- elog "your apache2 command. OpenRC users can append that string to" |
1510 |
- elog "APACHE2_OPTS in /etc/conf.d/apache2." |
1511 |
- elog |
1512 |
- elog "The apache module configuration file 70_mod_php.conf is" |
1513 |
- elog "provided (and maintained) by eselect-php." |
1514 |
- elog |
1515 |
- fi |
1516 |
- |
1517 |
- # Create the symlinks for php |
1518 |
- for m in ${SAPIS}; do |
1519 |
- [[ ${m} == 'embed' ]] && continue; |
1520 |
- if use $m ; then |
1521 |
- local ci=$(eselect php show $m) |
1522 |
- if [[ -z $ci ]]; then |
1523 |
- eselect php set $m php${SLOT} || die |
1524 |
- einfo "Switched ${m} to use php:${SLOT}" |
1525 |
- einfo |
1526 |
- elif [[ $ci != "php${SLOT}" ]] ; then |
1527 |
- elog "To switch $m to use php:${SLOT}, run" |
1528 |
- elog " eselect php set $m php${SLOT}" |
1529 |
- elog |
1530 |
- fi |
1531 |
- fi |
1532 |
- done |
1533 |
- |
1534 |
- # Remove dead symlinks for SAPIs that were just disabled. For |
1535 |
- # example, if the user has the cgi SAPI enabled, then he has an |
1536 |
- # eselect-php symlink for it. If he later reinstalls PHP with |
1537 |
- # USE="-cgi", that symlink will break. This call to eselect is |
1538 |
- # supposed to remove that dead link per bug 572436. |
1539 |
- eselect php cleanup || die |
1540 |
- |
1541 |
- if ! has "php${SLOT/./-}" ${PHP_TARGETS}; then |
1542 |
- elog "To build extensions for this version of PHP, you will need to" |
1543 |
- elog "add php${SLOT/./-} to your PHP_TARGETS USE_EXPAND variable." |
1544 |
- elog |
1545 |
- fi |
1546 |
- |
1547 |
- # Warn about the removal of PHP_INI_VERSION if the user has it set. |
1548 |
- if [[ -n "${PHP_INI_VERSION}" ]]; then |
1549 |
- ewarn 'The PHP_INI_VERSION variable has been phased out. You may' |
1550 |
- ewarn 'remove it from your configuration at your convenience. See' |
1551 |
- ewarn |
1552 |
- ewarn ' https://bugs.gentoo.org/611214' |
1553 |
- ewarn |
1554 |
- ewarn 'for more information.' |
1555 |
- fi |
1556 |
- |
1557 |
- elog "For details on how version slotting works, please see" |
1558 |
- elog "the wiki:" |
1559 |
- elog |
1560 |
- elog " https://wiki.gentoo.org/wiki/PHP" |
1561 |
- elog |
1562 |
-} |
1563 |
- |
1564 |
-pkg_postrm() { |
1565 |
- # This serves two purposes. First, if we have just removed the last |
1566 |
- # installed version of PHP, then this will remove any dead symlinks |
1567 |
- # belonging to eselect-php. Second, if a user upgrades slots from |
1568 |
- # (say) 5.6 to 7.0 and depcleans the old slot, then this will update |
1569 |
- # his existing symlinks to point to the new 7.0 installation. The |
1570 |
- # latter is bug 432962. |
1571 |
- # |
1572 |
- # Note: the eselect-php package may not be installed at this point, |
1573 |
- # so we can't die() if this command fails. |
1574 |
- eselect php cleanup |
1575 |
-} |
1576 |
|
1577 |
diff --git a/dev-lang/php/php-7.2.20.ebuild b/dev-lang/php/php-7.2.20.ebuild |
1578 |
deleted file mode 100644 |
1579 |
index 30968e0621d..00000000000 |
1580 |
--- a/dev-lang/php/php-7.2.20.ebuild |
1581 |
+++ /dev/null |
1582 |
@@ -1,749 +0,0 @@ |
1583 |
-# Copyright 1999-2019 Gentoo Authors |
1584 |
-# Distributed under the terms of the GNU General Public License v2 |
1585 |
- |
1586 |
-EAPI="7" |
1587 |
- |
1588 |
-inherit flag-o-matic systemd autotools |
1589 |
- |
1590 |
-DESCRIPTION="The PHP language runtime engine" |
1591 |
-HOMEPAGE="https://php.net/" |
1592 |
-SRC_URI="https://php.net/distributions/${P}.tar.xz" |
1593 |
- |
1594 |
-LICENSE="PHP-3.01 |
1595 |
- BSD |
1596 |
- Zend-2.0 |
1597 |
- bcmath? ( LGPL-2.1+ ) |
1598 |
- fpm? ( BSD-2 ) |
1599 |
- gd? ( gd ) |
1600 |
- unicode? ( BSD-2 LGPL-2.1 )" |
1601 |
- |
1602 |
-SLOT="$(ver_cut 1-2)" |
1603 |
-KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos" |
1604 |
- |
1605 |
-# We can build the following SAPIs in the given order |
1606 |
-SAPIS="embed cli cgi fpm apache2 phpdbg" |
1607 |
- |
1608 |
-# SAPIs and SAPI-specific USE flags (cli SAPI is default on): |
1609 |
-IUSE="${IUSE} |
1610 |
- ${SAPIS/cli/+cli} |
1611 |
- threads" |
1612 |
- |
1613 |
-IUSE="${IUSE} acl argon2 bcmath berkdb bzip2 calendar cdb cjk |
1614 |
- coverage +ctype curl debug |
1615 |
- enchant exif +fileinfo +filter firebird |
1616 |
- flatfile ftp gd gdbm gmp +hash +iconv imap inifile |
1617 |
- intl iodbc ipv6 +json kerberos ldap ldap-sasl libedit libressl lmdb |
1618 |
- mhash mssql mysql mysqli nls |
1619 |
- oci8-instant-client odbc +opcache pcntl pdo +phar +posix postgres qdbm |
1620 |
- readline recode selinux +session session-mm sharedmem |
1621 |
- +simplexml snmp soap sockets sodium spell sqlite ssl |
1622 |
- sysvipc systemd test tidy +tokenizer tokyocabinet truetype unicode wddx webp |
1623 |
- +xml xmlreader xmlwriter xmlrpc xpm xslt zip zip-encryption zlib" |
1624 |
- |
1625 |
-# The supported (that is, autodetected) versions of BDB are listed in |
1626 |
-# the ./configure script. Other versions *work*, but we need to stick to |
1627 |
-# the ones that can be detected to avoid a repeat of bug #564824. |
1628 |
-COMMON_DEPEND=" |
1629 |
- >=app-eselect/eselect-php-0.9.1[apache2?,fpm?] |
1630 |
- >=dev-libs/libpcre-8.32[unicode] |
1631 |
- fpm? ( acl? ( sys-apps/acl ) ) |
1632 |
- apache2? ( || ( >=www-servers/apache-2.4[apache2_modules_unixd,threads=] |
1633 |
- <www-servers/apache-2.4[threads=] ) ) |
1634 |
- argon2? ( app-crypt/argon2:= ) |
1635 |
- berkdb? ( || ( sys-libs/db:5.3 |
1636 |
- sys-libs/db:5.1 |
1637 |
- sys-libs/db:4.8 |
1638 |
- sys-libs/db:4.7 |
1639 |
- sys-libs/db:4.6 |
1640 |
- sys-libs/db:4.5 ) ) |
1641 |
- bzip2? ( app-arch/bzip2:0= ) |
1642 |
- cdb? ( || ( dev-db/cdb dev-db/tinycdb ) ) |
1643 |
- coverage? ( dev-util/lcov ) |
1644 |
- curl? ( >=net-misc/curl-7.10.5 ) |
1645 |
- enchant? ( <app-text/enchant-2.0:0 ) |
1646 |
- firebird? ( dev-db/firebird ) |
1647 |
- gd? ( virtual/jpeg:0 media-libs/libpng:0= sys-libs/zlib ) |
1648 |
- gdbm? ( >=sys-libs/gdbm-1.8.0:0= ) |
1649 |
- gmp? ( dev-libs/gmp:0= ) |
1650 |
- iconv? ( virtual/libiconv ) |
1651 |
- imap? ( virtual/imap-c-client[kerberos=,ssl=] ) |
1652 |
- intl? ( dev-libs/icu:= ) |
1653 |
- iodbc? ( dev-db/libiodbc ) |
1654 |
- kerberos? ( virtual/krb5 ) |
1655 |
- ldap? ( >=net-nds/openldap-1.2.11 ) |
1656 |
- ldap-sasl? ( dev-libs/cyrus-sasl >=net-nds/openldap-1.2.11 ) |
1657 |
- libedit? ( || ( sys-freebsd/freebsd-lib dev-libs/libedit ) ) |
1658 |
- lmdb? ( dev-db/lmdb:= ) |
1659 |
- mssql? ( dev-db/freetds[mssql] ) |
1660 |
- nls? ( sys-devel/gettext ) |
1661 |
- oci8-instant-client? ( dev-db/oracle-instantclient-basic ) |
1662 |
- odbc? ( >=dev-db/unixODBC-1.8.13 ) |
1663 |
- postgres? ( dev-db/postgresql:* ) |
1664 |
- qdbm? ( dev-db/qdbm ) |
1665 |
- readline? ( sys-libs/readline:0= ) |
1666 |
- recode? ( app-text/recode ) |
1667 |
- session-mm? ( dev-libs/mm ) |
1668 |
- simplexml? ( >=dev-libs/libxml2-2.6.8 ) |
1669 |
- snmp? ( >=net-analyzer/net-snmp-5.2 ) |
1670 |
- soap? ( >=dev-libs/libxml2-2.6.8 ) |
1671 |
- sodium? ( dev-libs/libsodium:= ) |
1672 |
- spell? ( >=app-text/aspell-0.50 ) |
1673 |
- sqlite? ( >=dev-db/sqlite-3.7.6.3 ) |
1674 |
- ssl? ( |
1675 |
- !libressl? ( dev-libs/openssl:0= ) |
1676 |
- libressl? ( dev-libs/libressl:0= ) |
1677 |
- ) |
1678 |
- tidy? ( || ( app-text/tidy-html5 app-text/htmltidy ) ) |
1679 |
- tokyocabinet? ( dev-db/tokyocabinet ) |
1680 |
- truetype? ( =media-libs/freetype-2* ) |
1681 |
- unicode? ( dev-libs/oniguruma:= ) |
1682 |
- wddx? ( >=dev-libs/libxml2-2.6.8 ) |
1683 |
- webp? ( media-libs/libwebp:0= ) |
1684 |
- xml? ( >=dev-libs/libxml2-2.6.8 ) |
1685 |
- xmlrpc? ( >=dev-libs/libxml2-2.6.8 virtual/libiconv ) |
1686 |
- xmlreader? ( >=dev-libs/libxml2-2.6.8 ) |
1687 |
- xmlwriter? ( >=dev-libs/libxml2-2.6.8 ) |
1688 |
- xpm? ( x11-libs/libXpm ) |
1689 |
- xslt? ( dev-libs/libxslt >=dev-libs/libxml2-2.6.8 ) |
1690 |
- zip? ( sys-libs/zlib:0= ) |
1691 |
- zip-encryption? ( >=dev-libs/libzip-1.2.0:= ) |
1692 |
- zlib? ( sys-libs/zlib:0= ) |
1693 |
-" |
1694 |
- |
1695 |
-RDEPEND="${COMMON_DEPEND} |
1696 |
- virtual/mta |
1697 |
- fpm? ( |
1698 |
- selinux? ( sec-policy/selinux-phpfpm ) |
1699 |
- systemd? ( sys-apps/systemd ) )" |
1700 |
- |
1701 |
-# Bison isn't actually needed when building from a release tarball |
1702 |
-# However, the configure script will warn if it's absent or if you |
1703 |
-# have an incompatible version installed. See bug 593278. |
1704 |
-DEPEND="${COMMON_DEPEND} |
1705 |
- app-arch/xz-utils |
1706 |
- >=sys-devel/bison-3.0.1" |
1707 |
- |
1708 |
-BDEPEND="virtual/pkgconfig" |
1709 |
- |
1710 |
-# Without USE=readline or libedit, the interactive "php -a" CLI will hang. |
1711 |
-REQUIRED_USE=" |
1712 |
- || ( cli cgi fpm apache2 embed phpdbg ) |
1713 |
- cli? ( ^^ ( readline libedit ) ) |
1714 |
- truetype? ( gd zlib ) |
1715 |
- webp? ( gd zlib ) |
1716 |
- cjk? ( gd zlib ) |
1717 |
- exif? ( gd zlib ) |
1718 |
- xpm? ( gd zlib ) |
1719 |
- gd? ( zlib ) |
1720 |
- simplexml? ( xml ) |
1721 |
- soap? ( xml ) |
1722 |
- wddx? ( xml ) |
1723 |
- xmlrpc? ( || ( xml iconv ) ) |
1724 |
- xmlreader? ( xml ) |
1725 |
- xslt? ( xml ) |
1726 |
- ldap-sasl? ( ldap ) |
1727 |
- mhash? ( hash ) |
1728 |
- phar? ( hash ) |
1729 |
- qdbm? ( !gdbm ) |
1730 |
- readline? ( !libedit ) |
1731 |
- recode? ( !imap !mysqli !mysql ) |
1732 |
- session-mm? ( session !threads ) |
1733 |
- mysql? ( hash || ( mysqli pdo ) ) |
1734 |
- mysqli? ( hash ) |
1735 |
- zip-encryption? ( zip ) |
1736 |
-" |
1737 |
-PATCHES=( |
1738 |
- "${FILESDIR}/php-freetype-2.9.1.patch" |
1739 |
- "${FILESDIR}/php-7.2.13-intl-use-icu-namespace.patch" |
1740 |
-) |
1741 |
- |
1742 |
-PHP_MV="$(ver_cut 1)" |
1743 |
- |
1744 |
-php_install_ini() { |
1745 |
- local phpsapi="${1}" |
1746 |
- |
1747 |
- # work out where we are installing the ini file |
1748 |
- php_set_ini_dir "${phpsapi}" |
1749 |
- |
1750 |
- # Always install the production INI file, bug 611214. |
1751 |
- local phpinisrc="php.ini-production-${phpsapi}" |
1752 |
- cp php.ini-production "${phpinisrc}" || die |
1753 |
- |
1754 |
- # default to /tmp for save_path, bug #282768 |
1755 |
- sed -e 's|^;session.save_path .*$|session.save_path = "'"${EPREFIX}"'/tmp"|g' -i "${phpinisrc}" || die |
1756 |
- |
1757 |
- # Set the extension dir |
1758 |
- sed -e "s|^extension_dir .*$|extension_dir = ${extension_dir}|g" \ |
1759 |
- -i "${phpinisrc}" || die |
1760 |
- |
1761 |
- # Set the include path to point to where we want to find PEAR packages |
1762 |
- sed -e 's|^;include_path = ".:/php/includes".*|include_path = ".:'"${EPREFIX}"'/usr/share/php'${PHP_MV}':'"${EPREFIX}"'/usr/share/php"|' -i "${phpinisrc}" || die |
1763 |
- |
1764 |
- dodir "${PHP_INI_DIR#${EPREFIX}}" |
1765 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
1766 |
- newins "${phpinisrc}" php.ini |
1767 |
- |
1768 |
- elog "Installing php.ini for ${phpsapi} into ${PHP_INI_DIR#${EPREFIX}}" |
1769 |
- elog |
1770 |
- |
1771 |
- dodir "${PHP_EXT_INI_DIR#${EPREFIX}}" |
1772 |
- dodir "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}" |
1773 |
- |
1774 |
- if use opcache; then |
1775 |
- elog "Adding opcache to $PHP_EXT_INI_DIR" |
1776 |
- echo "zend_extension=${PHP_DESTDIR}/$(get_libdir)/opcache.so" >> \ |
1777 |
- "${D}/${PHP_EXT_INI_DIR}"/opcache.ini |
1778 |
- dosym "${PHP_EXT_INI_DIR#${EPREFIX}}/opcache.ini" \ |
1779 |
- "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}/opcache.ini" |
1780 |
- fi |
1781 |
- |
1782 |
- # SAPI-specific handling |
1783 |
- if [[ "${sapi}" == "fpm" ]] ; then |
1784 |
- einfo "Installing FPM config files php-fpm.conf and www.conf" |
1785 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
1786 |
- doins sapi/fpm/php-fpm.conf |
1787 |
- insinto "${PHP_INI_DIR#${EPREFIX}}/fpm.d" |
1788 |
- doins sapi/fpm/www.conf |
1789 |
- fi |
1790 |
- |
1791 |
- dodoc php.ini-{development,production} |
1792 |
-} |
1793 |
- |
1794 |
-php_set_ini_dir() { |
1795 |
- PHP_INI_DIR="${EPREFIX}/etc/php/${1}-php${SLOT}" |
1796 |
- PHP_EXT_INI_DIR="${PHP_INI_DIR}/ext" |
1797 |
- PHP_EXT_INI_DIR_ACTIVE="${PHP_INI_DIR}/ext-active" |
1798 |
-} |
1799 |
- |
1800 |
-src_prepare() { |
1801 |
- default |
1802 |
- |
1803 |
- # In php-7.x, the FPM pool configuration files have been split off |
1804 |
- # of the main config. By default the pool config files go in |
1805 |
- # e.g. /etc/php-fpm.d, which isn't slotted. So here we move the |
1806 |
- # include directory to a subdirectory "fpm.d" of $PHP_INI_DIR. Later |
1807 |
- # we'll install the pool configuration file "www.conf" there. |
1808 |
- php_set_ini_dir fpm |
1809 |
- sed -i "s~^include=.*$~include=${PHP_INI_DIR}/fpm.d/*.conf~" \ |
1810 |
- sapi/fpm/php-fpm.conf.in \ |
1811 |
- || die 'failed to move the include directory in php-fpm.conf' |
1812 |
- |
1813 |
- # Bug 669566 - necessary so that build tools are updated for commands like pecl |
1814 |
- # Force rebuilding aclocal.m4 |
1815 |
- rm -f aclocal.m4 || die "failed to remove aclocal.m4 in src_prepare" |
1816 |
- eautoreconf |
1817 |
-} |
1818 |
- |
1819 |
-src_configure() { |
1820 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
1821 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
1822 |
- |
1823 |
- PHP_DESTDIR="${EPREFIX}/usr/$(get_libdir)/php${SLOT}" |
1824 |
- |
1825 |
- # The php-fpm config file wants localstatedir to be ${EPREFIX}/var |
1826 |
- # and not the Gentoo default ${EPREFIX}/var/lib. See bug 572002. |
1827 |
- local our_conf=( |
1828 |
- --prefix="${PHP_DESTDIR}" |
1829 |
- --mandir="${PHP_DESTDIR}/man" |
1830 |
- --infodir="${PHP_DESTDIR}/info" |
1831 |
- --libdir="${PHP_DESTDIR}/lib" |
1832 |
- --with-libdir="$(get_libdir)" |
1833 |
- --localstatedir="${EPREFIX}/var" |
1834 |
- --without-pear |
1835 |
- $(use_enable threads maintainer-zts) |
1836 |
- ) |
1837 |
- |
1838 |
- our_conf+=( |
1839 |
- $(use_with argon2 password-argon2 "${EPREFIX}/usr") |
1840 |
- $(use_enable bcmath bcmath) |
1841 |
- $(use_with bzip2 bz2 "${EPREFIX}/usr") |
1842 |
- $(use_enable calendar calendar) |
1843 |
- $(use_enable coverage gcov) |
1844 |
- $(use_enable ctype ctype) |
1845 |
- $(use_with curl curl "${EPREFIX}/usr") |
1846 |
- $(use_enable xml dom) |
1847 |
- $(use_with enchant enchant "${EPREFIX}/usr") |
1848 |
- $(use_enable exif exif) |
1849 |
- $(use_enable fileinfo fileinfo) |
1850 |
- $(use_enable filter filter) |
1851 |
- $(use_enable ftp ftp) |
1852 |
- $(use_with nls gettext "${EPREFIX}/usr") |
1853 |
- $(use_with gmp gmp "${EPREFIX}/usr") |
1854 |
- $(use_enable hash hash) |
1855 |
- $(use_with mhash mhash "${EPREFIX}/usr") |
1856 |
- $(use_with iconv iconv \ |
1857 |
- $(use elibc_glibc || use elibc_musl || use elibc_FreeBSD || echo "${EPREFIX}/usr")) |
1858 |
- $(use_enable intl intl) |
1859 |
- $(use_enable ipv6 ipv6) |
1860 |
- $(use_enable json json) |
1861 |
- $(use_with kerberos kerberos "${EPREFIX}/usr") |
1862 |
- $(use_enable xml libxml) |
1863 |
- $(use_with xml libxml-dir "${EPREFIX}/usr") |
1864 |
- $(use_enable unicode mbstring) |
1865 |
- $(use_with unicode onig "${EPREFIX}/usr") |
1866 |
- $(use_with ssl openssl "${EPREFIX}/usr") |
1867 |
- $(use_with ssl openssl-dir "${EPREFIX}/usr") |
1868 |
- $(use_enable pcntl pcntl) |
1869 |
- $(use_enable phar phar) |
1870 |
- $(use_enable pdo pdo) |
1871 |
- $(use_enable opcache opcache) |
1872 |
- $(use_with postgres pgsql "${EPREFIX}/usr") |
1873 |
- $(use_enable posix posix) |
1874 |
- $(use_with spell pspell "${EPREFIX}/usr") |
1875 |
- $(use_with recode recode "${EPREFIX}/usr") |
1876 |
- $(use_enable simplexml simplexml) |
1877 |
- $(use_enable sharedmem shmop) |
1878 |
- $(use_with snmp snmp "${EPREFIX}/usr") |
1879 |
- $(use_enable soap soap) |
1880 |
- $(use_enable sockets sockets) |
1881 |
- $(use_with sodium sodium "${EPREFIX}/usr") |
1882 |
- $(use_with sqlite sqlite3 "${EPREFIX}/usr") |
1883 |
- $(use_enable sysvipc sysvmsg) |
1884 |
- $(use_enable sysvipc sysvsem) |
1885 |
- $(use_enable sysvipc sysvshm) |
1886 |
- $(use_with tidy tidy "${EPREFIX}/usr") |
1887 |
- $(use_enable tokenizer tokenizer) |
1888 |
- $(use_enable wddx wddx) |
1889 |
- $(use_enable xml xml) |
1890 |
- $(use_enable xmlreader xmlreader) |
1891 |
- $(use_enable xmlwriter xmlwriter) |
1892 |
- $(use_with xmlrpc xmlrpc) |
1893 |
- $(use_with xslt xsl "${EPREFIX}/usr") |
1894 |
- $(use_enable zip zip) |
1895 |
- $(use_with zip-encryption libzip "${EPREFIX}/usr") |
1896 |
- $(use_with zlib zlib "${EPREFIX}/usr") |
1897 |
- $(use_enable debug debug) |
1898 |
- ) |
1899 |
- |
1900 |
- # DBA support |
1901 |
- if use cdb || use berkdb || use flatfile || use gdbm || use inifile \ |
1902 |
- || use qdbm || use lmdb || use tokyocabinet ; then |
1903 |
- our_conf+=( "--enable-dba${shared}" ) |
1904 |
- fi |
1905 |
- |
1906 |
- # DBA drivers support |
1907 |
- our_conf+=( |
1908 |
- $(use_with cdb cdb) |
1909 |
- $(use_with berkdb db4 "${EPREFIX}/usr") |
1910 |
- $(use_enable flatfile flatfile) |
1911 |
- $(use_with gdbm gdbm "${EPREFIX}/usr") |
1912 |
- $(use_enable inifile inifile) |
1913 |
- $(use_with qdbm qdbm "${EPREFIX}/usr") |
1914 |
- $(use_with lmdb lmdb "${EPREFIX}/usr") |
1915 |
- ) |
1916 |
- |
1917 |
- # Support for the GD graphics library |
1918 |
- our_conf+=( |
1919 |
- $(use_with truetype freetype-dir "${EPREFIX}/usr") |
1920 |
- $(use_enable cjk gd-jis-conv) |
1921 |
- $(use_with gd jpeg-dir "${EPREFIX}/usr") |
1922 |
- $(use_with gd png-dir "${EPREFIX}/usr") |
1923 |
- $(use_with xpm xpm-dir "${EPREFIX}/usr") |
1924 |
- ) |
1925 |
- if use webp; then |
1926 |
- our_conf+=( --with-webp-dir="${EPREFIX}/usr" ) |
1927 |
- fi |
1928 |
- # enable gd last, so configure can pick up the previous settings |
1929 |
- our_conf+=( $(use_with gd gd) ) |
1930 |
- |
1931 |
- # IMAP support |
1932 |
- if use imap ; then |
1933 |
- our_conf+=( |
1934 |
- $(use_with imap imap "${EPREFIX}/usr") |
1935 |
- $(use_with ssl imap-ssl "${EPREFIX}/usr") |
1936 |
- ) |
1937 |
- fi |
1938 |
- |
1939 |
- # Interbase/firebird support |
1940 |
- our_conf+=( $(use_with firebird interbase "${EPREFIX}/usr") ) |
1941 |
- |
1942 |
- # LDAP support |
1943 |
- if use ldap ; then |
1944 |
- our_conf+=( |
1945 |
- $(use_with ldap ldap "${EPREFIX}/usr") |
1946 |
- $(use_with ldap-sasl ldap-sasl "${EPREFIX}/usr") |
1947 |
- ) |
1948 |
- fi |
1949 |
- |
1950 |
- # MySQL support |
1951 |
- local mysqllib="mysqlnd" |
1952 |
- local mysqlilib="mysqlnd" |
1953 |
- |
1954 |
- our_conf+=( $(use_with mysqli mysqli "${mysqlilib}") ) |
1955 |
- |
1956 |
- local mysqlsock="${EPREFIX}/var/run/mysqld/mysqld.sock" |
1957 |
- if use mysql || use mysqli ; then |
1958 |
- our_conf+=( $(use_with mysql mysql-sock "${mysqlsock}") ) |
1959 |
- fi |
1960 |
- |
1961 |
- # ODBC support |
1962 |
- our_conf+=( |
1963 |
- $(use_with odbc unixODBC "${EPREFIX}/usr") |
1964 |
- $(use_with iodbc iodbc "${EPREFIX}/usr") |
1965 |
- ) |
1966 |
- |
1967 |
- # Oracle support |
1968 |
- our_conf+=( $(use_with oci8-instant-client oci8) ) |
1969 |
- |
1970 |
- # PDO support |
1971 |
- if use pdo ; then |
1972 |
- our_conf+=( |
1973 |
- $(use_with mssql pdo-dblib "${EPREFIX}/usr") |
1974 |
- $(use_with mysql pdo-mysql "${mysqllib}") |
1975 |
- $(use_with postgres pdo-pgsql) |
1976 |
- $(use_with sqlite pdo-sqlite "${EPREFIX}/usr") |
1977 |
- $(use_with firebird pdo-firebird "${EPREFIX}/usr") |
1978 |
- $(use_with odbc pdo-odbc "unixODBC,${EPREFIX}/usr") |
1979 |
- $(use_with oci8-instant-client pdo-oci) |
1980 |
- ) |
1981 |
- fi |
1982 |
- |
1983 |
- # readline/libedit support |
1984 |
- our_conf+=( |
1985 |
- $(use_with readline readline "${EPREFIX}/usr") |
1986 |
- $(use_with libedit libedit "${EPREFIX}/usr") |
1987 |
- ) |
1988 |
- |
1989 |
- # Session support |
1990 |
- if use session ; then |
1991 |
- our_conf+=( $(use_with session-mm mm "${EPREFIX}/usr") ) |
1992 |
- else |
1993 |
- our_conf+=( $(use_enable session session) ) |
1994 |
- fi |
1995 |
- |
1996 |
- # Use pic for shared modules such as apache2's mod_php |
1997 |
- our_conf+=( --with-pic ) |
1998 |
- |
1999 |
- # we use the system copy of pcre |
2000 |
- # --with-pcre-regex affects ext/pcre |
2001 |
- # --with-pcre-dir affects ext/filter and ext/zip |
2002 |
- # --with-pcre-valgrind cannot be enabled with system pcre |
2003 |
- # Many arches don't support pcre-jit |
2004 |
- our_conf+=( |
2005 |
- --with-pcre-regex="${EPREFIX}/usr" |
2006 |
- --with-pcre-dir="${EPREFIX}/usr" |
2007 |
- --without-pcre-valgrind |
2008 |
- --without-pcre-jit |
2009 |
- ) |
2010 |
- |
2011 |
- # Catch CFLAGS problems |
2012 |
- # Fixes bug #14067. |
2013 |
- # Changed order to run it in reverse for bug #32022 and #12021. |
2014 |
- replace-cpu-flags "k6*" "i586" |
2015 |
- |
2016 |
- # Cache the ./configure test results between SAPIs. |
2017 |
- our_conf+=( --cache-file="${T}/config.cache" ) |
2018 |
- |
2019 |
- # Support user-passed configuration parameters |
2020 |
- our_conf+=( ${EXTRA_ECONF:-} ) |
2021 |
- |
2022 |
- # Support the Apache2 extras, they must be set globally for all |
2023 |
- # SAPIs to work correctly, especially for external PHP extensions |
2024 |
- |
2025 |
- mkdir -p "${WORKDIR}/sapis-build" || die |
2026 |
- for one_sapi in $SAPIS ; do |
2027 |
- use "${one_sapi}" || continue |
2028 |
- php_set_ini_dir "${one_sapi}" |
2029 |
- |
2030 |
- # The BUILD_DIR variable is used to determine where to output |
2031 |
- # the files that autotools creates. This was all originally |
2032 |
- # based on the autotools-utils eclass. |
2033 |
- BUILD_DIR="${WORKDIR}/sapis-build/${one_sapi}" |
2034 |
- cp -a "${S}" "${BUILD_DIR}" || die |
2035 |
- cd "${BUILD_DIR}" || die |
2036 |
- |
2037 |
- local sapi_conf=( |
2038 |
- --with-config-file-path="${PHP_INI_DIR}" |
2039 |
- --with-config-file-scan-dir="${PHP_EXT_INI_DIR_ACTIVE}" |
2040 |
- ) |
2041 |
- |
2042 |
- for sapi in $SAPIS ; do |
2043 |
- case "$sapi" in |
2044 |
- cli|cgi|embed|fpm|phpdbg) |
2045 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
2046 |
- sapi_conf+=( "--enable-${sapi}" ) |
2047 |
- if [[ "fpm" == "${sapi}" ]] ; then |
2048 |
- sapi_conf+=( |
2049 |
- $(use_with acl fpm-acl) |
2050 |
- $(use_with systemd fpm-systemd) |
2051 |
- ) |
2052 |
- fi |
2053 |
- else |
2054 |
- sapi_conf+=( "--disable-${sapi}" ) |
2055 |
- fi |
2056 |
- ;; |
2057 |
- |
2058 |
- apache2) |
2059 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
2060 |
- sapi_conf+=( --with-apxs2="${EPREFIX}/usr/bin/apxs" ) |
2061 |
- else |
2062 |
- sapi_conf+=( --without-apxs2 ) |
2063 |
- fi |
2064 |
- ;; |
2065 |
- esac |
2066 |
- done |
2067 |
- |
2068 |
- # Construct the $myeconfargs array by concatenating $our_conf |
2069 |
- # (the common args) and $sapi_conf (the SAPI-specific args). |
2070 |
- local myeconfargs=( "${our_conf[@]}" ) |
2071 |
- myeconfargs+=( "${sapi_conf[@]}" ) |
2072 |
- |
2073 |
- pushd "${BUILD_DIR}" > /dev/null || die |
2074 |
- econf "${myeconfargs[@]}" |
2075 |
- popd > /dev/null || die |
2076 |
- done |
2077 |
-} |
2078 |
- |
2079 |
-src_compile() { |
2080 |
- # snmp seems to run during src_compile, too (bug #324739) |
2081 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
2082 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
2083 |
- |
2084 |
- for sapi in ${SAPIS} ; do |
2085 |
- if use "${sapi}"; then |
2086 |
- cd "${WORKDIR}/sapis-build/$sapi" || \ |
2087 |
- die "Failed to change dir to ${WORKDIR}/sapis-build/$1" |
2088 |
- emake |
2089 |
- fi |
2090 |
- done |
2091 |
-} |
2092 |
- |
2093 |
-src_install() { |
2094 |
- # see bug #324739 for what happens when we don't have that |
2095 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
2096 |
- |
2097 |
- # grab the first SAPI that got built and install common files from there |
2098 |
- local first_sapi="" |
2099 |
- for sapi in $SAPIS ; do |
2100 |
- if use $sapi ; then |
2101 |
- first_sapi=$sapi |
2102 |
- break |
2103 |
- fi |
2104 |
- done |
2105 |
- |
2106 |
- # Makefile forgets to create this before trying to write to it... |
2107 |
- dodir "${PHP_DESTDIR#${EPREFIX}}/bin" |
2108 |
- |
2109 |
- # Install php environment (without any sapis) |
2110 |
- cd "${WORKDIR}/sapis-build/$first_sapi" || die |
2111 |
- emake INSTALL_ROOT="${D}" \ |
2112 |
- install-build install-headers install-programs |
2113 |
- |
2114 |
- local extension_dir="$("${ED}/${PHP_DESTDIR#${EPREFIX}}/bin/php-config" --extension-dir)" |
2115 |
- |
2116 |
- # Create the directory where we'll put version-specific php scripts |
2117 |
- keepdir "/usr/share/php${PHP_MV}" |
2118 |
- |
2119 |
- local sapi="", file="" |
2120 |
- local sapi_list="" |
2121 |
- |
2122 |
- for sapi in ${SAPIS}; do |
2123 |
- if use "${sapi}" ; then |
2124 |
- einfo "Installing SAPI: ${sapi}" |
2125 |
- cd "${WORKDIR}/sapis-build/${sapi}" || die |
2126 |
- |
2127 |
- if [[ "${sapi}" == "apache2" ]] ; then |
2128 |
- # We're specifically not using emake install-sapi as libtool |
2129 |
- # may cause unnecessary relink failures (see bug #351266) |
2130 |
- insinto "${PHP_DESTDIR#${EPREFIX}}/apache2/" |
2131 |
- newins ".libs/libphp${PHP_MV}$(get_libname)" \ |
2132 |
- "libphp${PHP_MV}$(get_libname)" |
2133 |
- keepdir "/usr/$(get_libdir)/apache2/modules" |
2134 |
- else |
2135 |
- # needed each time, php_install_ini would reset it |
2136 |
- local dest="${PHP_DESTDIR#${EPREFIX}}" |
2137 |
- into "${dest}" |
2138 |
- case "$sapi" in |
2139 |
- cli) |
2140 |
- source="sapi/cli/php" |
2141 |
- ;; |
2142 |
- cgi) |
2143 |
- source="sapi/cgi/php-cgi" |
2144 |
- ;; |
2145 |
- fpm) |
2146 |
- source="sapi/fpm/php-fpm" |
2147 |
- ;; |
2148 |
- embed) |
2149 |
- source="libs/libphp${PHP_MV}$(get_libname)" |
2150 |
- ;; |
2151 |
- phpdbg) |
2152 |
- source="sapi/phpdbg/phpdbg" |
2153 |
- ;; |
2154 |
- *) |
2155 |
- die "unhandled sapi in src_install" |
2156 |
- ;; |
2157 |
- esac |
2158 |
- |
2159 |
- if [[ "${source}" == *"$(get_libname)" ]]; then |
2160 |
- dolib.so "${source}" |
2161 |
- else |
2162 |
- dobin "${source}" |
2163 |
- local name="$(basename ${source})" |
2164 |
- dosym "${dest}/bin/${name}" "/usr/bin/${name}${SLOT}" |
2165 |
- fi |
2166 |
- fi |
2167 |
- |
2168 |
- php_install_ini "${sapi}" |
2169 |
- |
2170 |
- # construct correct SAPI string for php-config |
2171 |
- # thanks to ferringb for the bash voodoo |
2172 |
- if [[ "${sapi}" == "apache2" ]]; then |
2173 |
- sapi_list="${sapi_list:+${sapi_list} }apache2handler" |
2174 |
- else |
2175 |
- sapi_list="${sapi_list:+${sapi_list} }${sapi}" |
2176 |
- fi |
2177 |
- fi |
2178 |
- done |
2179 |
- |
2180 |
- # Installing opcache module |
2181 |
- if use opcache ; then |
2182 |
- into "${PHP_DESTDIR#${EPREFIX}}" |
2183 |
- dolib.so "modules/opcache$(get_libname)" |
2184 |
- fi |
2185 |
- |
2186 |
- # Install env.d files |
2187 |
- newenvd "${FILESDIR}/20php5-envd" "20php${SLOT}" |
2188 |
- sed -e "s|/lib/|/$(get_libdir)/|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
2189 |
- sed -e "s|php5|php${SLOT}|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
2190 |
- |
2191 |
- # set php-config variable correctly (bug #278439) |
2192 |
- sed -e "s:^\(php_sapis=\)\".*\"$:\1\"${sapi_list}\":" -i \ |
2193 |
- "${ED}/usr/$(get_libdir)/php${SLOT}/bin/php-config" || die |
2194 |
- |
2195 |
- if use fpm ; then |
2196 |
- if use systemd; then |
2197 |
- systemd_newunit "${FILESDIR}/php-fpm_at.service" \ |
2198 |
- "php-fpm@${SLOT}.service" |
2199 |
- else |
2200 |
- systemd_newunit "${FILESDIR}/php-fpm_at-simple.service" \ |
2201 |
- "php-fpm@${SLOT}.service" |
2202 |
- fi |
2203 |
- fi |
2204 |
-} |
2205 |
- |
2206 |
-src_test() { |
2207 |
- echo ">>> Test phase [test]: ${CATEGORY}/${PF}" |
2208 |
- PHP_BIN="${WORKDIR}/sapis-build/cli/sapi/cli/php" |
2209 |
- if [[ ! -x "${PHP_BIN}" ]] ; then |
2210 |
- ewarn "Test phase requires USE=cli, skipping" |
2211 |
- return |
2212 |
- else |
2213 |
- export TEST_PHP_EXECUTABLE="${PHP_BIN}" |
2214 |
- fi |
2215 |
- |
2216 |
- if [[ -x "${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi" ]] ; then |
2217 |
- export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi" |
2218 |
- fi |
2219 |
- |
2220 |
- if [[ -x "${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" ]] ; then |
2221 |
- export TEST_PHPDBG_EXECUTABLE="${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" |
2222 |
- fi |
2223 |
- |
2224 |
- REPORT_EXIT_STATUS=1 "${TEST_PHP_EXECUTABLE}" -n -d \ |
2225 |
- "session.save_path=${T}" \ |
2226 |
- "${WORKDIR}/sapis-build/cli/run-tests.php" -n -q -d \ |
2227 |
- "session.save_path=${T}" |
2228 |
- |
2229 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
2230 |
- mv "${name}.out" "${name}.out.orig" 2>/dev/null || die |
2231 |
- done |
2232 |
- |
2233 |
- local failed="$(find -name '*.out')" |
2234 |
- if [[ ${failed} != "" ]] ; then |
2235 |
- ewarn "The following test cases failed unexpectedly:" |
2236 |
- for name in ${failed}; do |
2237 |
- ewarn " ${name/.out/}" |
2238 |
- done |
2239 |
- else |
2240 |
- einfo "No unexpected test failures, all fine" |
2241 |
- fi |
2242 |
- |
2243 |
- if [[ ${PHP_SHOW_UNEXPECTED_TEST_PASS} == "1" ]] ; then |
2244 |
- local passed="" |
2245 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
2246 |
- [[ -f "${name}.diff" ]] && continue |
2247 |
- passed="${passed} ${name}" |
2248 |
- done |
2249 |
- if [[ ${passed} != "" ]] ; then |
2250 |
- einfo "The following test cases passed unexpectedly:" |
2251 |
- for name in ${passed}; do |
2252 |
- ewarn " ${passed}" |
2253 |
- done |
2254 |
- else |
2255 |
- einfo "None of the known-to-fail tests passed, all fine" |
2256 |
- fi |
2257 |
- fi |
2258 |
-} |
2259 |
- |
2260 |
-pkg_postinst() { |
2261 |
- # Output some general info to the user |
2262 |
- if use apache2 ; then |
2263 |
- elog |
2264 |
- elog "To enable PHP in apache, you will need to add \"-D PHP\" to" |
2265 |
- elog "your apache2 command. OpenRC users can append that string to" |
2266 |
- elog "APACHE2_OPTS in /etc/conf.d/apache2." |
2267 |
- elog |
2268 |
- elog "The apache module configuration file 70_mod_php.conf is" |
2269 |
- elog "provided (and maintained) by eselect-php." |
2270 |
- elog |
2271 |
- fi |
2272 |
- |
2273 |
- # Create the symlinks for php |
2274 |
- for m in ${SAPIS}; do |
2275 |
- [[ ${m} == 'embed' ]] && continue; |
2276 |
- if use $m ; then |
2277 |
- local ci=$(eselect php show $m) |
2278 |
- if [[ -z $ci ]]; then |
2279 |
- eselect php set $m php${SLOT} || die |
2280 |
- einfo "Switched ${m} to use php:${SLOT}" |
2281 |
- einfo |
2282 |
- elif [[ $ci != "php${SLOT}" ]] ; then |
2283 |
- elog "To switch $m to use php:${SLOT}, run" |
2284 |
- elog " eselect php set $m php${SLOT}" |
2285 |
- elog |
2286 |
- fi |
2287 |
- fi |
2288 |
- done |
2289 |
- |
2290 |
- # Remove dead symlinks for SAPIs that were just disabled. For |
2291 |
- # example, if the user has the cgi SAPI enabled, then he has an |
2292 |
- # eselect-php symlink for it. If he later reinstalls PHP with |
2293 |
- # USE="-cgi", that symlink will break. This call to eselect is |
2294 |
- # supposed to remove that dead link per bug 572436. |
2295 |
- eselect php cleanup || die |
2296 |
- |
2297 |
- if ! has "php${SLOT/./-}" ${PHP_TARGETS}; then |
2298 |
- elog "To build extensions for this version of PHP, you will need to" |
2299 |
- elog "add php${SLOT/./-} to your PHP_TARGETS USE_EXPAND variable." |
2300 |
- elog |
2301 |
- fi |
2302 |
- |
2303 |
- # Warn about the removal of PHP_INI_VERSION if the user has it set. |
2304 |
- if [[ -n "${PHP_INI_VERSION}" ]]; then |
2305 |
- ewarn 'The PHP_INI_VERSION variable has been phased out. You may' |
2306 |
- ewarn 'remove it from your configuration at your convenience. See' |
2307 |
- ewarn |
2308 |
- ewarn ' https://bugs.gentoo.org/611214' |
2309 |
- ewarn |
2310 |
- ewarn 'for more information.' |
2311 |
- fi |
2312 |
- |
2313 |
- elog "For details on how version slotting works, please see" |
2314 |
- elog "the wiki:" |
2315 |
- elog |
2316 |
- elog " https://wiki.gentoo.org/wiki/PHP" |
2317 |
- elog |
2318 |
-} |
2319 |
- |
2320 |
-pkg_postrm() { |
2321 |
- # This serves two purposes. First, if we have just removed the last |
2322 |
- # installed version of PHP, then this will remove any dead symlinks |
2323 |
- # belonging to eselect-php. Second, if a user upgrades slots from |
2324 |
- # (say) 5.6 to 7.0 and depcleans the old slot, then this will update |
2325 |
- # his existing symlinks to point to the new 7.0 installation. The |
2326 |
- # latter is bug 432962. |
2327 |
- # |
2328 |
- # Note: the eselect-php package may not be installed at this point, |
2329 |
- # so we can't die() if this command fails. |
2330 |
- eselect php cleanup |
2331 |
-} |
2332 |
|
2333 |
diff --git a/dev-lang/php/php-7.3.7-r1.ebuild b/dev-lang/php/php-7.3.7-r1.ebuild |
2334 |
deleted file mode 100644 |
2335 |
index 34041772dbc..00000000000 |
2336 |
--- a/dev-lang/php/php-7.3.7-r1.ebuild |
2337 |
+++ /dev/null |
2338 |
@@ -1,750 +0,0 @@ |
2339 |
-# Copyright 1999-2019 Gentoo Authors |
2340 |
-# Distributed under the terms of the GNU General Public License v2 |
2341 |
- |
2342 |
-EAPI="7" |
2343 |
- |
2344 |
-inherit flag-o-matic systemd autotools |
2345 |
- |
2346 |
-MY_PV=${PV/_rc/RC} |
2347 |
-DESCRIPTION="The PHP language runtime engine" |
2348 |
-HOMEPAGE="https://php.net/" |
2349 |
-SRC_URI="https://php.net/distributions/${P}.tar.xz" |
2350 |
- |
2351 |
-LICENSE="PHP-3.01 |
2352 |
- BSD |
2353 |
- Zend-2.0 |
2354 |
- bcmath? ( LGPL-2.1+ ) |
2355 |
- fpm? ( BSD-2 ) |
2356 |
- gd? ( gd ) |
2357 |
- unicode? ( BSD-2 LGPL-2.1 )" |
2358 |
- |
2359 |
-SLOT="$(ver_cut 1-2)" |
2360 |
-KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos" |
2361 |
- |
2362 |
-S="${WORKDIR}/${PN}-${MY_PV}" |
2363 |
- |
2364 |
-# We can build the following SAPIs in the given order |
2365 |
-SAPIS="embed cli cgi fpm apache2 phpdbg" |
2366 |
- |
2367 |
-# SAPIs and SAPI-specific USE flags (cli SAPI is default on): |
2368 |
-IUSE="${IUSE} |
2369 |
- ${SAPIS/cli/+cli} |
2370 |
- threads" |
2371 |
- |
2372 |
-IUSE="${IUSE} acl argon2 bcmath berkdb bzip2 calendar cdb cjk |
2373 |
- coverage +ctype curl debug |
2374 |
- enchant exif +fileinfo +filter firebird |
2375 |
- flatfile ftp gd gdbm gmp +hash +iconv imap inifile |
2376 |
- intl iodbc ipv6 +json kerberos ldap ldap-sasl libedit libressl lmdb |
2377 |
- mhash mssql mysql mysqli nls |
2378 |
- oci8-instant-client odbc +opcache pcntl pdo +phar +posix postgres qdbm |
2379 |
- readline recode selinux +session session-mm sharedmem |
2380 |
- +simplexml snmp soap sockets sodium spell sqlite ssl |
2381 |
- sysvipc systemd test tidy +tokenizer tokyocabinet truetype unicode wddx webp |
2382 |
- +xml xmlreader xmlwriter xmlrpc xpm xslt zip zip-encryption zlib" |
2383 |
- |
2384 |
-# The supported (that is, autodetected) versions of BDB are listed in |
2385 |
-# the ./configure script. Other versions *work*, but we need to stick to |
2386 |
-# the ones that can be detected to avoid a repeat of bug #564824. |
2387 |
-COMMON_DEPEND=" |
2388 |
- >=app-eselect/eselect-php-0.9.1[apache2?,fpm?] |
2389 |
- >=dev-libs/libpcre2-10.30[unicode] |
2390 |
- fpm? ( acl? ( sys-apps/acl ) ) |
2391 |
- apache2? ( || ( >=www-servers/apache-2.4[apache2_modules_unixd,threads=] |
2392 |
- <www-servers/apache-2.4[threads=] ) ) |
2393 |
- argon2? ( app-crypt/argon2:= ) |
2394 |
- berkdb? ( || ( sys-libs/db:5.3 |
2395 |
- sys-libs/db:5.1 |
2396 |
- sys-libs/db:4.8 |
2397 |
- sys-libs/db:4.7 |
2398 |
- sys-libs/db:4.6 |
2399 |
- sys-libs/db:4.5 ) ) |
2400 |
- bzip2? ( app-arch/bzip2:0= ) |
2401 |
- cdb? ( || ( dev-db/cdb dev-db/tinycdb ) ) |
2402 |
- coverage? ( dev-util/lcov ) |
2403 |
- curl? ( >=net-misc/curl-7.10.5 ) |
2404 |
- enchant? ( <app-text/enchant-2.0:0 ) |
2405 |
- firebird? ( dev-db/firebird ) |
2406 |
- gd? ( virtual/jpeg:0 media-libs/libpng:0= >=sys-libs/zlib-1.2.0.4 ) |
2407 |
- gdbm? ( >=sys-libs/gdbm-1.8.0:0= ) |
2408 |
- gmp? ( dev-libs/gmp:0= ) |
2409 |
- iconv? ( virtual/libiconv ) |
2410 |
- imap? ( virtual/imap-c-client[kerberos=,ssl=] ) |
2411 |
- intl? ( dev-libs/icu:= ) |
2412 |
- iodbc? ( dev-db/libiodbc ) |
2413 |
- kerberos? ( virtual/krb5 ) |
2414 |
- ldap? ( >=net-nds/openldap-1.2.11 ) |
2415 |
- ldap-sasl? ( dev-libs/cyrus-sasl >=net-nds/openldap-1.2.11 ) |
2416 |
- libedit? ( || ( sys-freebsd/freebsd-lib dev-libs/libedit ) ) |
2417 |
- lmdb? ( dev-db/lmdb:= ) |
2418 |
- mssql? ( dev-db/freetds[mssql] ) |
2419 |
- nls? ( sys-devel/gettext ) |
2420 |
- oci8-instant-client? ( dev-db/oracle-instantclient-basic ) |
2421 |
- odbc? ( >=dev-db/unixODBC-1.8.13 ) |
2422 |
- postgres? ( dev-db/postgresql:* ) |
2423 |
- qdbm? ( dev-db/qdbm ) |
2424 |
- readline? ( sys-libs/readline:0= ) |
2425 |
- recode? ( app-text/recode ) |
2426 |
- session-mm? ( dev-libs/mm ) |
2427 |
- simplexml? ( >=dev-libs/libxml2-2.6.8 ) |
2428 |
- snmp? ( >=net-analyzer/net-snmp-5.2 ) |
2429 |
- soap? ( >=dev-libs/libxml2-2.6.8 ) |
2430 |
- sodium? ( dev-libs/libsodium:= ) |
2431 |
- spell? ( >=app-text/aspell-0.50 ) |
2432 |
- sqlite? ( >=dev-db/sqlite-3.7.6.3 ) |
2433 |
- ssl? ( |
2434 |
- !libressl? ( >=dev-libs/openssl-1.0.1:0= ) |
2435 |
- libressl? ( dev-libs/libressl:0= ) |
2436 |
- ) |
2437 |
- tidy? ( || ( app-text/tidy-html5 app-text/htmltidy ) ) |
2438 |
- tokyocabinet? ( dev-db/tokyocabinet ) |
2439 |
- truetype? ( =media-libs/freetype-2* ) |
2440 |
- unicode? ( dev-libs/oniguruma:= ) |
2441 |
- wddx? ( >=dev-libs/libxml2-2.6.8 ) |
2442 |
- webp? ( media-libs/libwebp:0= ) |
2443 |
- xml? ( >=dev-libs/libxml2-2.6.8 ) |
2444 |
- xmlrpc? ( >=dev-libs/libxml2-2.6.8 virtual/libiconv ) |
2445 |
- xmlreader? ( >=dev-libs/libxml2-2.6.8 ) |
2446 |
- xmlwriter? ( >=dev-libs/libxml2-2.6.8 ) |
2447 |
- xpm? ( x11-libs/libXpm ) |
2448 |
- xslt? ( dev-libs/libxslt >=dev-libs/libxml2-2.6.8 ) |
2449 |
- zip? ( >=sys-libs/zlib-1.2.0.4:0= ) |
2450 |
- zip-encryption? ( >=dev-libs/libzip-1.2.0:= ) |
2451 |
- zlib? ( >=sys-libs/zlib-1.2.0.4:0= ) |
2452 |
-" |
2453 |
- |
2454 |
-RDEPEND="${COMMON_DEPEND} |
2455 |
- virtual/mta |
2456 |
- fpm? ( |
2457 |
- selinux? ( sec-policy/selinux-phpfpm ) |
2458 |
- systemd? ( sys-apps/systemd ) )" |
2459 |
- |
2460 |
-# Bison isn't actually needed when building from a release tarball |
2461 |
-# However, the configure script will warn if it's absent or if you |
2462 |
-# have an incompatible version installed. See bug 593278. |
2463 |
-DEPEND="${COMMON_DEPEND} |
2464 |
- app-arch/xz-utils |
2465 |
- >=sys-devel/bison-3.0.1" |
2466 |
- |
2467 |
-BDEPEND="virtual/pkgconfig" |
2468 |
- |
2469 |
-# Without USE=readline or libedit, the interactive "php -a" CLI will hang. |
2470 |
-REQUIRED_USE=" |
2471 |
- || ( cli cgi fpm apache2 embed phpdbg ) |
2472 |
- cli? ( ^^ ( readline libedit ) ) |
2473 |
- truetype? ( gd zlib ) |
2474 |
- webp? ( gd zlib ) |
2475 |
- cjk? ( gd zlib ) |
2476 |
- exif? ( gd zlib ) |
2477 |
- xpm? ( gd zlib ) |
2478 |
- gd? ( zlib ) |
2479 |
- simplexml? ( xml ) |
2480 |
- soap? ( xml ) |
2481 |
- wddx? ( xml ) |
2482 |
- xmlrpc? ( || ( xml iconv ) ) |
2483 |
- xmlreader? ( xml ) |
2484 |
- xslt? ( xml ) |
2485 |
- ldap-sasl? ( ldap ) |
2486 |
- mhash? ( hash ) |
2487 |
- phar? ( hash ) |
2488 |
- qdbm? ( !gdbm ) |
2489 |
- readline? ( !libedit ) |
2490 |
- recode? ( !imap !mysqli !mysql ) |
2491 |
- session-mm? ( session !threads ) |
2492 |
- mysql? ( || ( mysqli pdo ) ) |
2493 |
- zip-encryption? ( zip ) |
2494 |
-" |
2495 |
-PATCHES=( |
2496 |
- "${FILESDIR}/php-freetype-2.9.1.patch" |
2497 |
-) |
2498 |
- |
2499 |
-PHP_MV="$(ver_cut 1)" |
2500 |
- |
2501 |
-php_install_ini() { |
2502 |
- local phpsapi="${1}" |
2503 |
- |
2504 |
- # work out where we are installing the ini file |
2505 |
- php_set_ini_dir "${phpsapi}" |
2506 |
- |
2507 |
- # Always install the production INI file, bug 611214. |
2508 |
- local phpinisrc="php.ini-production-${phpsapi}" |
2509 |
- cp php.ini-production "${phpinisrc}" || die |
2510 |
- |
2511 |
- # default to /tmp for save_path, bug #282768 |
2512 |
- sed -e 's|^;session.save_path .*$|session.save_path = "'"${EPREFIX}"'/tmp"|g' -i "${phpinisrc}" || die |
2513 |
- |
2514 |
- # Set the extension dir |
2515 |
- sed -e "s|^extension_dir .*$|extension_dir = ${extension_dir}|g" \ |
2516 |
- -i "${phpinisrc}" || die |
2517 |
- |
2518 |
- # Set the include path to point to where we want to find PEAR packages |
2519 |
- sed -e 's|^;include_path = ".:/php/includes".*|include_path = ".:'"${EPREFIX}"'/usr/share/php'${PHP_MV}':'"${EPREFIX}"'/usr/share/php"|' -i "${phpinisrc}" || die |
2520 |
- |
2521 |
- dodir "${PHP_INI_DIR#${EPREFIX}}" |
2522 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
2523 |
- newins "${phpinisrc}" php.ini |
2524 |
- |
2525 |
- elog "Installing php.ini for ${phpsapi} into ${PHP_INI_DIR#${EPREFIX}}" |
2526 |
- elog |
2527 |
- |
2528 |
- dodir "${PHP_EXT_INI_DIR#${EPREFIX}}" |
2529 |
- dodir "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}" |
2530 |
- |
2531 |
- if use opcache; then |
2532 |
- elog "Adding opcache to $PHP_EXT_INI_DIR" |
2533 |
- echo "zend_extension=${PHP_DESTDIR}/$(get_libdir)/opcache.so" >> \ |
2534 |
- "${D}/${PHP_EXT_INI_DIR}"/opcache.ini |
2535 |
- dosym "${PHP_EXT_INI_DIR#${EPREFIX}}/opcache.ini" \ |
2536 |
- "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}/opcache.ini" |
2537 |
- fi |
2538 |
- |
2539 |
- # SAPI-specific handling |
2540 |
- if [[ "${sapi}" == "fpm" ]] ; then |
2541 |
- einfo "Installing FPM config files php-fpm.conf and www.conf" |
2542 |
- insinto "${PHP_INI_DIR#${EPREFIX}}" |
2543 |
- doins sapi/fpm/php-fpm.conf |
2544 |
- insinto "${PHP_INI_DIR#${EPREFIX}}/fpm.d" |
2545 |
- doins sapi/fpm/www.conf |
2546 |
- fi |
2547 |
- |
2548 |
- dodoc php.ini-{development,production} |
2549 |
-} |
2550 |
- |
2551 |
-php_set_ini_dir() { |
2552 |
- PHP_INI_DIR="${EPREFIX}/etc/php/${1}-php${SLOT}" |
2553 |
- PHP_EXT_INI_DIR="${PHP_INI_DIR}/ext" |
2554 |
- PHP_EXT_INI_DIR_ACTIVE="${PHP_INI_DIR}/ext-active" |
2555 |
-} |
2556 |
- |
2557 |
-src_prepare() { |
2558 |
- default |
2559 |
- |
2560 |
- # In php-7.x, the FPM pool configuration files have been split off |
2561 |
- # of the main config. By default the pool config files go in |
2562 |
- # e.g. /etc/php-fpm.d, which isn't slotted. So here we move the |
2563 |
- # include directory to a subdirectory "fpm.d" of $PHP_INI_DIR. Later |
2564 |
- # we'll install the pool configuration file "www.conf" there. |
2565 |
- php_set_ini_dir fpm |
2566 |
- sed -i "s~^include=.*$~include=${PHP_INI_DIR}/fpm.d/*.conf~" \ |
2567 |
- sapi/fpm/php-fpm.conf.in \ |
2568 |
- || die 'failed to move the include directory in php-fpm.conf' |
2569 |
- |
2570 |
- # Bug 669566 - necessary so that build tools are updated for commands like pecl |
2571 |
- # Force rebuilding aclocal.m4 |
2572 |
- rm -f aclocal.m4 || die "failed to remove aclocal.m4 in src_prepare" |
2573 |
- eautoreconf |
2574 |
-} |
2575 |
- |
2576 |
-src_configure() { |
2577 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
2578 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
2579 |
- |
2580 |
- PHP_DESTDIR="${EPREFIX}/usr/$(get_libdir)/php${SLOT}" |
2581 |
- |
2582 |
- # The php-fpm config file wants localstatedir to be ${EPREFIX}/var |
2583 |
- # and not the Gentoo default ${EPREFIX}/var/lib. See bug 572002. |
2584 |
- local our_conf=( |
2585 |
- --prefix="${PHP_DESTDIR}" |
2586 |
- --mandir="${PHP_DESTDIR}/man" |
2587 |
- --infodir="${PHP_DESTDIR}/info" |
2588 |
- --libdir="${PHP_DESTDIR}/lib" |
2589 |
- --with-libdir="$(get_libdir)" |
2590 |
- --localstatedir="${EPREFIX}/var" |
2591 |
- --without-pear |
2592 |
- $(use_enable threads maintainer-zts) |
2593 |
- ) |
2594 |
- |
2595 |
- our_conf+=( |
2596 |
- $(use_with argon2 password-argon2 "${EPREFIX}/usr") |
2597 |
- $(use_enable bcmath bcmath) |
2598 |
- $(use_with bzip2 bz2 "${EPREFIX}/usr") |
2599 |
- $(use_enable calendar calendar) |
2600 |
- $(use_enable coverage gcov) |
2601 |
- $(use_enable ctype ctype) |
2602 |
- $(use_with curl curl "${EPREFIX}/usr") |
2603 |
- $(use_enable xml dom) |
2604 |
- $(use_with enchant enchant "${EPREFIX}/usr") |
2605 |
- $(use_enable exif exif) |
2606 |
- $(use_enable fileinfo fileinfo) |
2607 |
- $(use_enable filter filter) |
2608 |
- $(use_enable ftp ftp) |
2609 |
- $(use_with nls gettext "${EPREFIX}/usr") |
2610 |
- $(use_with gmp gmp "${EPREFIX}/usr") |
2611 |
- $(use_enable hash hash) |
2612 |
- $(use_with mhash mhash "${EPREFIX}/usr") |
2613 |
- $(use_with iconv iconv \ |
2614 |
- $(use elibc_glibc || use elibc_musl || use elibc_FreeBSD || echo "${EPREFIX}/usr")) |
2615 |
- $(use_enable intl intl) |
2616 |
- $(use_enable ipv6 ipv6) |
2617 |
- $(use_enable json json) |
2618 |
- $(use_with kerberos kerberos "${EPREFIX}/usr") |
2619 |
- $(use_enable xml libxml) |
2620 |
- $(use_with xml libxml-dir "${EPREFIX}/usr") |
2621 |
- $(use_enable unicode mbstring) |
2622 |
- $(use_with unicode onig "${EPREFIX}/usr") |
2623 |
- $(use_with ssl openssl "${EPREFIX}/usr") |
2624 |
- $(use_with ssl openssl-dir "${EPREFIX}/usr") |
2625 |
- $(use_enable pcntl pcntl) |
2626 |
- $(use_enable phar phar) |
2627 |
- $(use_enable pdo pdo) |
2628 |
- $(use_enable opcache opcache) |
2629 |
- $(use_with postgres pgsql "${EPREFIX}/usr") |
2630 |
- $(use_enable posix posix) |
2631 |
- $(use_with spell pspell "${EPREFIX}/usr") |
2632 |
- $(use_with recode recode "${EPREFIX}/usr") |
2633 |
- $(use_enable simplexml simplexml) |
2634 |
- $(use_enable sharedmem shmop) |
2635 |
- $(use_with snmp snmp "${EPREFIX}/usr") |
2636 |
- $(use_enable soap soap) |
2637 |
- $(use_enable sockets sockets) |
2638 |
- $(use_with sodium sodium "${EPREFIX}/usr") |
2639 |
- $(use_with sqlite sqlite3 "${EPREFIX}/usr") |
2640 |
- $(use_enable sysvipc sysvmsg) |
2641 |
- $(use_enable sysvipc sysvsem) |
2642 |
- $(use_enable sysvipc sysvshm) |
2643 |
- $(use_with tidy tidy "${EPREFIX}/usr") |
2644 |
- $(use_enable tokenizer tokenizer) |
2645 |
- $(use_enable wddx wddx) |
2646 |
- $(use_enable xml xml) |
2647 |
- $(use_enable xmlreader xmlreader) |
2648 |
- $(use_enable xmlwriter xmlwriter) |
2649 |
- $(use_with xmlrpc xmlrpc) |
2650 |
- $(use_with xslt xsl "${EPREFIX}/usr") |
2651 |
- $(use_enable zip zip) |
2652 |
- $(use_with zip-encryption libzip "${EPREFIX}/usr") |
2653 |
- $(use_with zlib zlib "${EPREFIX}/usr") |
2654 |
- $(use_enable debug debug) |
2655 |
- ) |
2656 |
- |
2657 |
- # DBA support |
2658 |
- if use cdb || use berkdb || use flatfile || use gdbm || use inifile \ |
2659 |
- || use qdbm || use lmdb || use tokyocabinet ; then |
2660 |
- our_conf+=( "--enable-dba${shared}" ) |
2661 |
- fi |
2662 |
- |
2663 |
- # DBA drivers support |
2664 |
- our_conf+=( |
2665 |
- $(use_with cdb cdb) |
2666 |
- $(use_with berkdb db4 "${EPREFIX}/usr") |
2667 |
- $(use_enable flatfile flatfile) |
2668 |
- $(use_with gdbm gdbm "${EPREFIX}/usr") |
2669 |
- $(use_enable inifile inifile) |
2670 |
- $(use_with qdbm qdbm "${EPREFIX}/usr") |
2671 |
- $(use_with lmdb lmdb "${EPREFIX}/usr") |
2672 |
- ) |
2673 |
- |
2674 |
- # Support for the GD graphics library |
2675 |
- our_conf+=( |
2676 |
- $(use_with truetype freetype-dir "${EPREFIX}/usr") |
2677 |
- $(use_enable cjk gd-jis-conv) |
2678 |
- $(use_with gd jpeg-dir "${EPREFIX}/usr") |
2679 |
- $(use_with gd png-dir "${EPREFIX}/usr") |
2680 |
- $(use_with xpm xpm-dir "${EPREFIX}/usr") |
2681 |
- ) |
2682 |
- if use webp; then |
2683 |
- our_conf+=( --with-webp-dir="${EPREFIX}/usr" ) |
2684 |
- fi |
2685 |
- # enable gd last, so configure can pick up the previous settings |
2686 |
- our_conf+=( $(use_with gd gd) ) |
2687 |
- |
2688 |
- # IMAP support |
2689 |
- if use imap ; then |
2690 |
- our_conf+=( |
2691 |
- $(use_with imap imap "${EPREFIX}/usr") |
2692 |
- $(use_with ssl imap-ssl "${EPREFIX}/usr") |
2693 |
- ) |
2694 |
- fi |
2695 |
- |
2696 |
- # Interbase/firebird support |
2697 |
- our_conf+=( $(use_with firebird interbase "${EPREFIX}/usr") ) |
2698 |
- |
2699 |
- # LDAP support |
2700 |
- if use ldap ; then |
2701 |
- our_conf+=( |
2702 |
- $(use_with ldap ldap "${EPREFIX}/usr") |
2703 |
- $(use_with ldap-sasl ldap-sasl "${EPREFIX}/usr") |
2704 |
- ) |
2705 |
- fi |
2706 |
- |
2707 |
- # MySQL support |
2708 |
- local mysqllib="mysqlnd" |
2709 |
- local mysqlilib="mysqlnd" |
2710 |
- |
2711 |
- our_conf+=( $(use_with mysqli mysqli "${mysqlilib}") ) |
2712 |
- |
2713 |
- local mysqlsock="${EPREFIX}/var/run/mysqld/mysqld.sock" |
2714 |
- if use mysql || use mysqli ; then |
2715 |
- our_conf+=( $(use_with mysql mysql-sock "${mysqlsock}") ) |
2716 |
- fi |
2717 |
- |
2718 |
- # ODBC support |
2719 |
- our_conf+=( |
2720 |
- $(use_with odbc unixODBC "${EPREFIX}/usr") |
2721 |
- $(use_with iodbc iodbc "${EPREFIX}/usr") |
2722 |
- ) |
2723 |
- |
2724 |
- # Oracle support |
2725 |
- our_conf+=( $(use_with oci8-instant-client oci8) ) |
2726 |
- |
2727 |
- # PDO support |
2728 |
- if use pdo ; then |
2729 |
- our_conf+=( |
2730 |
- $(use_with mssql pdo-dblib "${EPREFIX}/usr") |
2731 |
- $(use_with mysql pdo-mysql "${mysqllib}") |
2732 |
- $(use_with postgres pdo-pgsql) |
2733 |
- $(use_with sqlite pdo-sqlite "${EPREFIX}/usr") |
2734 |
- $(use_with firebird pdo-firebird "${EPREFIX}/usr") |
2735 |
- $(use_with odbc pdo-odbc "unixODBC,${EPREFIX}/usr") |
2736 |
- $(use_with oci8-instant-client pdo-oci) |
2737 |
- ) |
2738 |
- fi |
2739 |
- |
2740 |
- # readline/libedit support |
2741 |
- our_conf+=( |
2742 |
- $(use_with readline readline "${EPREFIX}/usr") |
2743 |
- $(use_with libedit libedit "${EPREFIX}/usr") |
2744 |
- ) |
2745 |
- |
2746 |
- # Session support |
2747 |
- if use session ; then |
2748 |
- our_conf+=( $(use_with session-mm mm "${EPREFIX}/usr") ) |
2749 |
- else |
2750 |
- our_conf+=( $(use_enable session session) ) |
2751 |
- fi |
2752 |
- |
2753 |
- # Use pic for shared modules such as apache2's mod_php |
2754 |
- our_conf+=( --with-pic ) |
2755 |
- |
2756 |
- # we use the system copy of pcre |
2757 |
- # --with-pcre-regex affects ext/pcre |
2758 |
- # --with-pcre-dir affects ext/filter and ext/zip |
2759 |
- # --with-pcre-valgrind cannot be enabled with system pcre |
2760 |
- # Many arches don't support pcre-jit |
2761 |
- our_conf+=( |
2762 |
- --with-pcre-regex="${EPREFIX}/usr" |
2763 |
- --with-pcre-dir="${EPREFIX}/usr" |
2764 |
- --without-pcre-valgrind |
2765 |
- --without-pcre-jit |
2766 |
- ) |
2767 |
- |
2768 |
- # Catch CFLAGS problems |
2769 |
- # Fixes bug #14067. |
2770 |
- # Changed order to run it in reverse for bug #32022 and #12021. |
2771 |
- replace-cpu-flags "k6*" "i586" |
2772 |
- |
2773 |
- # Cache the ./configure test results between SAPIs. |
2774 |
- our_conf+=( --cache-file="${T}/config.cache" ) |
2775 |
- |
2776 |
- # Support user-passed configuration parameters |
2777 |
- our_conf+=( ${EXTRA_ECONF:-} ) |
2778 |
- |
2779 |
- # Support the Apache2 extras, they must be set globally for all |
2780 |
- # SAPIs to work correctly, especially for external PHP extensions |
2781 |
- |
2782 |
- mkdir -p "${WORKDIR}/sapis-build" || die |
2783 |
- for one_sapi in $SAPIS ; do |
2784 |
- use "${one_sapi}" || continue |
2785 |
- php_set_ini_dir "${one_sapi}" |
2786 |
- |
2787 |
- # The BUILD_DIR variable is used to determine where to output |
2788 |
- # the files that autotools creates. This was all originally |
2789 |
- # based on the autotools-utils eclass. |
2790 |
- BUILD_DIR="${WORKDIR}/sapis-build/${one_sapi}" |
2791 |
- cp -a "${S}" "${BUILD_DIR}" || die |
2792 |
- cd "${BUILD_DIR}" || die |
2793 |
- |
2794 |
- local sapi_conf=( |
2795 |
- --with-config-file-path="${PHP_INI_DIR}" |
2796 |
- --with-config-file-scan-dir="${PHP_EXT_INI_DIR_ACTIVE}" |
2797 |
- ) |
2798 |
- |
2799 |
- for sapi in $SAPIS ; do |
2800 |
- case "$sapi" in |
2801 |
- cli|cgi|embed|fpm|phpdbg) |
2802 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
2803 |
- sapi_conf+=( "--enable-${sapi}" ) |
2804 |
- if [[ "fpm" == "${sapi}" ]] ; then |
2805 |
- sapi_conf+=( |
2806 |
- $(use_with acl fpm-acl) |
2807 |
- $(use_with systemd fpm-systemd) |
2808 |
- ) |
2809 |
- fi |
2810 |
- else |
2811 |
- sapi_conf+=( "--disable-${sapi}" ) |
2812 |
- fi |
2813 |
- ;; |
2814 |
- |
2815 |
- apache2) |
2816 |
- if [[ "${one_sapi}" == "${sapi}" ]] ; then |
2817 |
- sapi_conf+=( --with-apxs2="${EPREFIX}/usr/bin/apxs" ) |
2818 |
- else |
2819 |
- sapi_conf+=( --without-apxs2 ) |
2820 |
- fi |
2821 |
- ;; |
2822 |
- esac |
2823 |
- done |
2824 |
- |
2825 |
- # Construct the $myeconfargs array by concatenating $our_conf |
2826 |
- # (the common args) and $sapi_conf (the SAPI-specific args). |
2827 |
- local myeconfargs=( "${our_conf[@]}" ) |
2828 |
- myeconfargs+=( "${sapi_conf[@]}" ) |
2829 |
- |
2830 |
- pushd "${BUILD_DIR}" > /dev/null || die |
2831 |
- econf "${myeconfargs[@]}" |
2832 |
- popd > /dev/null || die |
2833 |
- done |
2834 |
-} |
2835 |
- |
2836 |
-src_compile() { |
2837 |
- # snmp seems to run during src_compile, too (bug #324739) |
2838 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
2839 |
- addpredict /var/lib/net-snmp/mib_indexes #nowarn |
2840 |
- |
2841 |
- for sapi in ${SAPIS} ; do |
2842 |
- if use "${sapi}"; then |
2843 |
- cd "${WORKDIR}/sapis-build/$sapi" || \ |
2844 |
- die "Failed to change dir to ${WORKDIR}/sapis-build/$1" |
2845 |
- emake |
2846 |
- fi |
2847 |
- done |
2848 |
-} |
2849 |
- |
2850 |
-src_install() { |
2851 |
- # see bug #324739 for what happens when we don't have that |
2852 |
- addpredict /usr/share/snmp/mibs/.index #nowarn |
2853 |
- |
2854 |
- # grab the first SAPI that got built and install common files from there |
2855 |
- local first_sapi="" |
2856 |
- for sapi in $SAPIS ; do |
2857 |
- if use $sapi ; then |
2858 |
- first_sapi=$sapi |
2859 |
- break |
2860 |
- fi |
2861 |
- done |
2862 |
- |
2863 |
- # Makefile forgets to create this before trying to write to it... |
2864 |
- dodir "${PHP_DESTDIR#${EPREFIX}}/bin" |
2865 |
- |
2866 |
- # Install php environment (without any sapis) |
2867 |
- cd "${WORKDIR}/sapis-build/$first_sapi" || die |
2868 |
- emake INSTALL_ROOT="${D}" \ |
2869 |
- install-build install-headers install-programs |
2870 |
- |
2871 |
- local extension_dir="$("${ED}/${PHP_DESTDIR#${EPREFIX}}/bin/php-config" --extension-dir)" |
2872 |
- |
2873 |
- # Create the directory where we'll put version-specific php scripts |
2874 |
- keepdir "/usr/share/php${PHP_MV}" |
2875 |
- |
2876 |
- local sapi="", file="" |
2877 |
- local sapi_list="" |
2878 |
- |
2879 |
- for sapi in ${SAPIS}; do |
2880 |
- if use "${sapi}" ; then |
2881 |
- einfo "Installing SAPI: ${sapi}" |
2882 |
- cd "${WORKDIR}/sapis-build/${sapi}" || die |
2883 |
- |
2884 |
- if [[ "${sapi}" == "apache2" ]] ; then |
2885 |
- # We're specifically not using emake install-sapi as libtool |
2886 |
- # may cause unnecessary relink failures (see bug #351266) |
2887 |
- insinto "${PHP_DESTDIR#${EPREFIX}}/apache2/" |
2888 |
- newins ".libs/libphp${PHP_MV}$(get_libname)" \ |
2889 |
- "libphp${PHP_MV}$(get_libname)" |
2890 |
- keepdir "/usr/$(get_libdir)/apache2/modules" |
2891 |
- else |
2892 |
- # needed each time, php_install_ini would reset it |
2893 |
- local dest="${PHP_DESTDIR#${EPREFIX}}" |
2894 |
- into "${dest}" |
2895 |
- case "$sapi" in |
2896 |
- cli) |
2897 |
- source="sapi/cli/php" |
2898 |
- ;; |
2899 |
- cgi) |
2900 |
- source="sapi/cgi/php-cgi" |
2901 |
- ;; |
2902 |
- fpm) |
2903 |
- source="sapi/fpm/php-fpm" |
2904 |
- ;; |
2905 |
- embed) |
2906 |
- source="libs/libphp${PHP_MV}$(get_libname)" |
2907 |
- ;; |
2908 |
- phpdbg) |
2909 |
- source="sapi/phpdbg/phpdbg" |
2910 |
- ;; |
2911 |
- *) |
2912 |
- die "unhandled sapi in src_install" |
2913 |
- ;; |
2914 |
- esac |
2915 |
- |
2916 |
- if [[ "${source}" == *"$(get_libname)" ]]; then |
2917 |
- dolib.so "${source}" |
2918 |
- else |
2919 |
- dobin "${source}" |
2920 |
- local name="$(basename ${source})" |
2921 |
- dosym "${dest}/bin/${name}" "/usr/bin/${name}${SLOT}" |
2922 |
- fi |
2923 |
- fi |
2924 |
- |
2925 |
- php_install_ini "${sapi}" |
2926 |
- |
2927 |
- # construct correct SAPI string for php-config |
2928 |
- # thanks to ferringb for the bash voodoo |
2929 |
- if [[ "${sapi}" == "apache2" ]]; then |
2930 |
- sapi_list="${sapi_list:+${sapi_list} }apache2handler" |
2931 |
- else |
2932 |
- sapi_list="${sapi_list:+${sapi_list} }${sapi}" |
2933 |
- fi |
2934 |
- fi |
2935 |
- done |
2936 |
- |
2937 |
- # Installing opcache module |
2938 |
- if use opcache ; then |
2939 |
- into "${PHP_DESTDIR#${EPREFIX}}" |
2940 |
- dolib.so "modules/opcache$(get_libname)" |
2941 |
- fi |
2942 |
- |
2943 |
- # Install env.d files |
2944 |
- newenvd "${FILESDIR}/20php5-envd" "20php${SLOT}" |
2945 |
- sed -e "s|/lib/|/$(get_libdir)/|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
2946 |
- sed -e "s|php5|php${SLOT}|g" -i "${ED}/etc/env.d/20php${SLOT}" || die |
2947 |
- |
2948 |
- # set php-config variable correctly (bug #278439) |
2949 |
- sed -e "s:^\(php_sapis=\)\".*\"$:\1\"${sapi_list}\":" -i \ |
2950 |
- "${ED}/usr/$(get_libdir)/php${SLOT}/bin/php-config" || die |
2951 |
- |
2952 |
- if use fpm ; then |
2953 |
- if use systemd; then |
2954 |
- systemd_newunit "${FILESDIR}/php-fpm_at.service" \ |
2955 |
- "php-fpm@${SLOT}.service" |
2956 |
- else |
2957 |
- systemd_newunit "${FILESDIR}/php-fpm_at-simple.service" \ |
2958 |
- "php-fpm@${SLOT}.service" |
2959 |
- fi |
2960 |
- fi |
2961 |
-} |
2962 |
- |
2963 |
-src_test() { |
2964 |
- echo ">>> Test phase [test]: ${CATEGORY}/${PF}" |
2965 |
- PHP_BIN="${WORKDIR}/sapis-build/cli/sapi/cli/php" |
2966 |
- if [[ ! -x "${PHP_BIN}" ]] ; then |
2967 |
- ewarn "Test phase requires USE=cli, skipping" |
2968 |
- return |
2969 |
- else |
2970 |
- export TEST_PHP_EXECUTABLE="${PHP_BIN}" |
2971 |
- fi |
2972 |
- |
2973 |
- if [[ -x "${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi" ]] ; then |
2974 |
- export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi" |
2975 |
- fi |
2976 |
- |
2977 |
- if [[ -x "${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" ]] ; then |
2978 |
- export TEST_PHPDBG_EXECUTABLE="${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" |
2979 |
- fi |
2980 |
- |
2981 |
- REPORT_EXIT_STATUS=1 "${TEST_PHP_EXECUTABLE}" -n -d \ |
2982 |
- "session.save_path=${T}" \ |
2983 |
- "${WORKDIR}/sapis-build/cli/run-tests.php" -n -q -d \ |
2984 |
- "session.save_path=${T}" |
2985 |
- |
2986 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
2987 |
- mv "${name}.out" "${name}.out.orig" 2>/dev/null || die |
2988 |
- done |
2989 |
- |
2990 |
- local failed="$(find -name '*.out')" |
2991 |
- if [[ ${failed} != "" ]] ; then |
2992 |
- ewarn "The following test cases failed unexpectedly:" |
2993 |
- for name in ${failed}; do |
2994 |
- ewarn " ${name/.out/}" |
2995 |
- done |
2996 |
- else |
2997 |
- einfo "No unexpected test failures, all fine" |
2998 |
- fi |
2999 |
- |
3000 |
- if [[ ${PHP_SHOW_UNEXPECTED_TEST_PASS} == "1" ]] ; then |
3001 |
- local passed="" |
3002 |
- for name in ${EXPECTED_TEST_FAILURES}; do |
3003 |
- [[ -f "${name}.diff" ]] && continue |
3004 |
- passed="${passed} ${name}" |
3005 |
- done |
3006 |
- if [[ ${passed} != "" ]] ; then |
3007 |
- einfo "The following test cases passed unexpectedly:" |
3008 |
- for name in ${passed}; do |
3009 |
- ewarn " ${passed}" |
3010 |
- done |
3011 |
- else |
3012 |
- einfo "None of the known-to-fail tests passed, all fine" |
3013 |
- fi |
3014 |
- fi |
3015 |
-} |
3016 |
- |
3017 |
-pkg_postinst() { |
3018 |
- # Output some general info to the user |
3019 |
- if use apache2 ; then |
3020 |
- elog |
3021 |
- elog "To enable PHP in apache, you will need to add \"-D PHP\" to" |
3022 |
- elog "your apache2 command. OpenRC users can append that string to" |
3023 |
- elog "APACHE2_OPTS in /etc/conf.d/apache2." |
3024 |
- elog |
3025 |
- elog "The apache module configuration file 70_mod_php.conf is" |
3026 |
- elog "provided (and maintained) by eselect-php." |
3027 |
- elog |
3028 |
- fi |
3029 |
- |
3030 |
- # Create the symlinks for php |
3031 |
- for m in ${SAPIS}; do |
3032 |
- [[ ${m} == 'embed' ]] && continue; |
3033 |
- if use $m ; then |
3034 |
- local ci=$(eselect php show $m) |
3035 |
- if [[ -z $ci ]]; then |
3036 |
- eselect php set $m php${SLOT} || die |
3037 |
- einfo "Switched ${m} to use php:${SLOT}" |
3038 |
- einfo |
3039 |
- elif [[ $ci != "php${SLOT}" ]] ; then |
3040 |
- elog "To switch $m to use php:${SLOT}, run" |
3041 |
- elog " eselect php set $m php${SLOT}" |
3042 |
- elog |
3043 |
- fi |
3044 |
- fi |
3045 |
- done |
3046 |
- |
3047 |
- # Remove dead symlinks for SAPIs that were just disabled. For |
3048 |
- # example, if the user has the cgi SAPI enabled, then he has an |
3049 |
- # eselect-php symlink for it. If he later reinstalls PHP with |
3050 |
- # USE="-cgi", that symlink will break. This call to eselect is |
3051 |
- # supposed to remove that dead link per bug 572436. |
3052 |
- eselect php cleanup || die |
3053 |
- |
3054 |
- if ! has "php${SLOT/./-}" ${PHP_TARGETS}; then |
3055 |
- elog "To build extensions for this version of PHP, you will need to" |
3056 |
- elog "add php${SLOT/./-} to your PHP_TARGETS USE_EXPAND variable." |
3057 |
- elog |
3058 |
- fi |
3059 |
- |
3060 |
- # Warn about the removal of PHP_INI_VERSION if the user has it set. |
3061 |
- if [[ -n "${PHP_INI_VERSION}" ]]; then |
3062 |
- ewarn 'The PHP_INI_VERSION variable has been phased out. You may' |
3063 |
- ewarn 'remove it from your configuration at your convenience. See' |
3064 |
- ewarn |
3065 |
- ewarn ' https://bugs.gentoo.org/611214' |
3066 |
- ewarn |
3067 |
- ewarn 'for more information.' |
3068 |
- fi |
3069 |
- |
3070 |
- elog "For details on how version slotting works, please see" |
3071 |
- elog "the wiki:" |
3072 |
- elog |
3073 |
- elog " https://wiki.gentoo.org/wiki/PHP" |
3074 |
- elog |
3075 |
-} |
3076 |
- |
3077 |
-pkg_postrm() { |
3078 |
- # This serves two purposes. First, if we have just removed the last |
3079 |
- # installed version of PHP, then this will remove any dead symlinks |
3080 |
- # belonging to eselect-php. Second, if a user upgrades slots from |
3081 |
- # (say) 5.6 to 7.0 and depcleans the old slot, then this will update |
3082 |
- # his existing symlinks to point to the new 7.0 installation. The |
3083 |
- # latter is bug 432962. |
3084 |
- # |
3085 |
- # Note: the eselect-php package may not be installed at this point, |
3086 |
- # so we can't die() if this command fails. |
3087 |
- eselect php cleanup |
3088 |
-} |