Gentoo Archives: gentoo-commits

From: Brian Evans <grknight@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: profiles/, dev-lang/php/
Date: Mon, 30 Dec 2019 15:09:38
Message-Id: 1577718554.4f3225d163eabd647b8b354df1194e61a52e6fe0.grknight@gentoo
1 commit: 4f3225d163eabd647b8b354df1194e61a52e6fe0
2 Author: Brian Evans <grknight <AT> gentoo <DOT> org>
3 AuthorDate: Mon Dec 30 15:08:22 2019 +0000
4 Commit: Brian Evans <grknight <AT> gentoo <DOT> org>
5 CommitDate: Mon Dec 30 15:09:14 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4f3225d1
7
8 dev-lang/php: Drop 5.6 slot
9
10 Bug: https://bugs.gentoo.org/651784
11 Signed-off-by: Brian Evans <grknight <AT> gentoo.org>
12
13 dev-lang/php/Manifest | 2 -
14 dev-lang/php/metadata.xml | 5 -
15 dev-lang/php/php-5.6.40-r7.ebuild | 788 --------------------------------------
16 profiles/package.mask | 6 -
17 4 files changed, 801 deletions(-)
18
19 diff --git a/dev-lang/php/Manifest b/dev-lang/php/Manifest
20 index 69dc032b082..bb426d59d83 100644
21 --- a/dev-lang/php/Manifest
22 +++ b/dev-lang/php/Manifest
23 @@ -1,4 +1,3 @@
24 -DIST php-5.6.40.tar.xz 12472236 BLAKE2B f41147eaec9b15e965540f9e871691cc88848dd619bae6af85e7bba0130b71ce91bad5cdbbadbb537c42df83369f5c731007339a9d9e21e689e913c135201afc SHA512 997b5a952a60cf9166671cc91fcc34c674dd62bfd5cb0a9cdf3fdf2d088b5d19943d94c1cf193f8ab71fc4957d9a9a4c7c2fb8826f937501c1c0a0858f10e329
25 DIST php-7.1.33.tar.xz 12370228 BLAKE2B 610f501c1729ca3f5fa6f104b9f229046cf1e497f2fdc1194b80b4a5f9ca7f799dc6a458de34dd7a87976b7252ba2f548a8d689e4b2a45c025f1807ab8489f12 SHA512 ed37a79e3402c767f20e55c1cbe27957cc78240eafc719fffccd7d29ae10a45112aa0f29082f56133cd9c25f2750e9e57246d95b4f38d766f49bd29d1397eb1d
26 DIST php-7.2.24.tar.xz 12302284 BLAKE2B 3c864e72d9fce1f13295385e20708a632087b2e4ffdc9e0012191cb2e17a3530f26797ad03c595bea60cccf850fe17028f2a379e50f32bd4db82530e0fcd727f SHA512 39597b8328cb4d5284288bdce8dd9c7ef8446e46914de93203700efaf67f85ad5b69df777bea14eef9160b233fb79bcb60f6750c0df011bbf610b62a524689e3
27 DIST php-7.2.25.tar.xz 12278980 BLAKE2B f556263e5ae00694e76a54d364aa31c33e51277e3ddaaf59a8dc6453cd2ea82d2229ad54149925cbbb2ed7983887652fb3c3c6e7be5a04192b7a619b0c4c7eab SHA512 b803284ef3aac178646095200c4bb3635d6dcaffd967ea94960905cec9a76835f745606d45e383b917d7e6b118708bc05025728444a3123d3c09e06350cb277b
28 @@ -8,4 +7,3 @@ DIST php-7.3.12.tar.xz 12095212 BLAKE2B a0377883103dc0fa7625297f4b7f4777fc6d72b8
29 DIST php-7.3.13.tar.xz 12102012 BLAKE2B 32a346470ea0d0a3db873ae94b5e4dcc650c25e24db244ea94417f092e0458a0825cb99e9c3429000ee5cbd50120824d9bd2a58a7ed2ada1f39c6d7c41b2ba08 SHA512 d0624b3b841fed49d9cea56b17e7c8c7abf8e6572832b6f86c98f48c23f86690c310b460eae27a6fcd41fbfbc2e8a4b56f6bfb0c738fa1db36ce3795454d7798
30 DIST php-7.4.0.tar.xz 10232208 BLAKE2B 2282ab5c177d362f03f370e71dcaf925aa7752b0c1656d292760961adb4027e34f73a44c97ab5760956e466457241509f0dc6e5d9387898815a1bc88cdf45a9e SHA512 a44ce901b64a5f3f973ed323987e570e5459923149a34d0aa036990c3a42956d28b836a25dc3baef0d90aaee432df08a72d59966174218163b9579493027115c
31 DIST php-7.4.1.tar.xz 10245600 BLAKE2B fcbb7de0e9ab74820ca8fdd234cd20908ed8e559e6eeffd576e285a5f4b4b31506ec2e11cc5926464257e08289207462f4b373833b8130500e0944f64dbf6cf5 SHA512 2dd152bdca52ece160feff799622fd4bdd88e0664f629e6149fd14ede6c304dfc40c164fcd9200c041b26342d6248010cf9b53e30c1a8d31640dc3b24d25c4da
32 -DIST php-patches-7.1.33bp.tar.bz2 39945 BLAKE2B 9f7137f61b7ea07cc263b054401a319042f5a40d6cdaf3561a45778ae009e3279c72f2a6a0f9c97805bc39acef1c8c9d72d290c2ce873f44209fb2d65d620810 SHA512 8e36fb57bdadfcc4e976ecb7dc8f44290dc3b507eb27f4445aa2c8eba528e7cb53286e7fd9b1b9141f12fd6e29278282e4f0eb6445ed06046dd48a1d5d1bc789
33
34 diff --git a/dev-lang/php/metadata.xml b/dev-lang/php/metadata.xml
35 index 47de79c79a9..462b7c8d5b4 100644
36 --- a/dev-lang/php/metadata.xml
37 +++ b/dev-lang/php/metadata.xml
38 @@ -26,9 +26,6 @@
39 <flag name="inifile">Add dbm support for .ini files</flag>
40 <flag name="json">Enable JSON support</flag>
41 <flag name="ldap-sasl">Add SASL support for the PHP LDAP extension</flag>
42 - <flag name="libmysqlclient">
43 - Use libmyslclient driver for mysql, mysqli, PDO_Mysql (not recommended)
44 - </flag>
45 <flag name="lmdb">Enable support for <pkg>dev-db/lmdb</pkg> db backend</flag>
46 <flag name="intl">
47 Enables the intl extension for extended internalization support
48 @@ -52,7 +49,6 @@
49 <flag name="sodium">
50 Enable support for crypto through <pkg>dev-libs/libsodium</pkg>
51 </flag>
52 - <flag name="sybase-ct">Add support for Sybase-CT</flag>
53 <flag name="sysvipc">
54 Support for System V-compatible inter-process communication
55 </flag>
56 @@ -62,7 +58,6 @@
57 <flag name="xmlreader">Enable XMLReader support</flag>
58 <flag name="xmlwriter">Enable XMLWriter support</flag>
59 <flag name="xslt">Enable the XSL extension</flag>
60 - <flag name="vpx">Enable webp support for GD in php-5.x</flag>
61 <flag name="wddx">Add support for Web Distributed Data eXchange</flag>
62 <flag name="webp">Enable webp support for GD in php-7.x</flag>
63 <flag name="zip-encryption">Enable ZIP file encryption from <pkg>dev-libs/libzip</pkg></flag>
64
65 diff --git a/dev-lang/php/php-5.6.40-r7.ebuild b/dev-lang/php/php-5.6.40-r7.ebuild
66 deleted file mode 100644
67 index 80f4eacde0c..00000000000
68 --- a/dev-lang/php/php-5.6.40-r7.ebuild
69 +++ /dev/null
70 @@ -1,788 +0,0 @@
71 -# Copyright 1999-2019 Gentoo Authors
72 -# Distributed under the terms of the GNU General Public License v2
73 -
74 -EAPI="7"
75 -
76 -inherit autotools flag-o-matic systemd
77 -
78 -PATCH_V="7.1.33bp"
79 -
80 -DESCRIPTION="The PHP language runtime engine"
81 -HOMEPAGE="https://secure.php.net/"
82 -SRC_URI="https://php.net/distributions/${P}.tar.xz
83 - https://gitweb.gentoo.org/proj/php-patches.git/snapshot/php-patches-${PATCH_V}.tar.bz2"
84 -
85 -LICENSE="PHP-3.01
86 - BSD
87 - Zend-2.0
88 - bcmath? ( LGPL-2.1+ )
89 - fpm? ( BSD-2 )
90 - gd? ( gd )
91 - unicode? ( BSD-2 LGPL-2.1 )"
92 -
93 -SLOT="$(ver_cut 1-2)"
94 -KEYWORDS="~alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
95 -
96 -# We can build the following SAPIs in the given order
97 -SAPIS="embed cli cgi fpm apache2"
98 -
99 -# SAPIs and SAPI-specific USE flags (cli SAPI is default on):
100 -IUSE="${IUSE}
101 - ${SAPIS/cli/+cli}
102 - threads"
103 -
104 -IUSE="${IUSE} acl bcmath berkdb bzip2 calendar cdb cjk
105 - coverage crypt +ctype curl debug
106 - enchant exif +fileinfo +filter firebird
107 - +flatfile ftp gd gdbm gmp +hash +iconv imap inifile
108 - intl iodbc ipv6 +json kerberos ldap ldap-sasl libedit libressl
109 - mhash mssql mysql libmysqlclient mysqli nls
110 - oci8-instant-client odbc +opcache pcntl pdo +phar +posix postgres qdbm
111 - readline recode selinux +session sharedmem
112 - +simplexml snmp soap sockets spell sqlite ssl
113 - sybase-ct sysvipc systemd tidy +tokenizer truetype unicode vpx wddx
114 - +xml xmlreader xmlwriter xmlrpc xpm xslt zip zlib"
115 -
116 -# The supported (that is, autodetected) versions of BDB are listed in
117 -# the ./configure script. Other versions *work*, but we need to stick to
118 -# the ones that can be detected to avoid a repeat of bug #564824.
119 -COMMON_DEPEND="
120 - >=app-eselect/eselect-php-0.9.1[apache2?,fpm?]
121 - >=dev-libs/libpcre-8.32[unicode]
122 - fpm? ( acl? ( sys-apps/acl ) )
123 - apache2? ( www-servers/apache[apache2_modules_unixd(+),threads=] )
124 - berkdb? ( || ( sys-libs/db:5.3
125 - sys-libs/db:5.1
126 - sys-libs/db:4.8
127 - sys-libs/db:4.7
128 - sys-libs/db:4.6
129 - sys-libs/db:4.5 ) )
130 - bzip2? ( app-arch/bzip2:0= )
131 - cdb? ( || ( dev-db/cdb dev-db/tinycdb ) )
132 - cjk? ( !gd? (
133 - virtual/jpeg:0
134 - media-libs/libpng:0=
135 - sys-libs/zlib:0=
136 - ) )
137 - coverage? ( dev-util/lcov )
138 - crypt? ( >=dev-libs/libmcrypt-2.4 )
139 - curl? ( >=net-misc/curl-7.10.5 )
140 - enchant? ( app-text/enchant )
141 - exif? ( !gd? (
142 - virtual/jpeg:0
143 - media-libs/libpng:0=
144 - sys-libs/zlib:0=
145 - ) )
146 - firebird? ( dev-db/firebird )
147 - gd? ( virtual/jpeg:0 media-libs/libpng:0= sys-libs/zlib:0= )
148 - gdbm? ( >=sys-libs/gdbm-1.8.0:0= )
149 - gmp? ( dev-libs/gmp:0= )
150 - iconv? ( virtual/libiconv )
151 - imap? ( >=virtual/imap-c-client-2[kerberos=,ssl=] )
152 - intl? ( dev-libs/icu:= )
153 - iodbc? ( dev-db/libiodbc )
154 - kerberos? ( virtual/krb5 )
155 - ldap? ( >=net-nds/openldap-1.2.11 )
156 - ldap-sasl? ( dev-libs/cyrus-sasl >=net-nds/openldap-1.2.11 )
157 - libedit? ( || ( sys-freebsd/freebsd-lib dev-libs/libedit ) )
158 - mssql? ( dev-db/freetds[mssql] )
159 - libmysqlclient? (
160 - mysql? ( <dev-db/mysql-connector-c-8.0:0= )
161 - mysqli? ( <dev-db/mysql-connector-c-8.0:0= )
162 - )
163 - nls? ( sys-devel/gettext )
164 - oci8-instant-client? ( dev-db/oracle-instantclient-basic )
165 - odbc? ( >=dev-db/unixODBC-1.8.13 )
166 - postgres? ( dev-db/postgresql:* )
167 - qdbm? ( dev-db/qdbm )
168 - readline? ( sys-libs/readline:0= )
169 - recode? ( app-text/recode )
170 - sharedmem? ( dev-libs/mm )
171 - simplexml? ( >=dev-libs/libxml2-2.6.8 )
172 - snmp? ( >=net-analyzer/net-snmp-5.2 )
173 - soap? ( >=dev-libs/libxml2-2.6.8 )
174 - spell? ( >=app-text/aspell-0.50 )
175 - sqlite? ( >=dev-db/sqlite-3.7.6.3 )
176 - ssl? (
177 - !libressl? ( dev-libs/openssl:0= )
178 - libressl? ( dev-libs/libressl:0= )
179 - )
180 - sybase-ct? ( dev-db/freetds )
181 - tidy? ( app-text/htmltidy )
182 - truetype? (
183 - =media-libs/freetype-2*
184 - >=media-libs/t1lib-5.0.0
185 - !gd? (
186 - virtual/jpeg:0 media-libs/libpng:0= sys-libs/zlib:0= )
187 - )
188 - unicode? ( dev-libs/oniguruma:= )
189 - vpx? ( media-libs/libvpx:0= )
190 - wddx? ( >=dev-libs/libxml2-2.6.8 )
191 - xml? ( >=dev-libs/libxml2-2.6.8 )
192 - xmlrpc? ( >=dev-libs/libxml2-2.6.8 virtual/libiconv )
193 - xmlreader? ( >=dev-libs/libxml2-2.6.8 )
194 - xmlwriter? ( >=dev-libs/libxml2-2.6.8 )
195 - xpm? (
196 - x11-libs/libXpm
197 - virtual/jpeg:0
198 - media-libs/libpng:0= sys-libs/zlib:0=
199 - )
200 - xslt? ( dev-libs/libxslt >=dev-libs/libxml2-2.6.8 )
201 - zip? ( sys-libs/zlib:0= )
202 - zlib? ( sys-libs/zlib:0= )
203 -"
204 -
205 -RDEPEND="${COMMON_DEPEND}
206 - virtual/mta
207 - fpm? (
208 - selinux? ( sec-policy/selinux-phpfpm )
209 - systemd? ( sys-apps/systemd ) )"
210 -
211 -DEPEND="${COMMON_DEPEND}
212 - app-arch/xz-utils
213 - >=sys-devel/bison-3.0.1
214 - sys-devel/flex
215 - >=sys-devel/m4-1.4.3
216 - >=sys-devel/libtool-1.5.18"
217 -
218 -# Without USE=readline or libedit, the interactive "php -a" CLI will hang.
219 -REQUIRED_USE="
220 - || ( cli cgi fpm apache2 embed )
221 - cli? ( ^^ ( readline libedit ) )
222 - truetype? ( gd zlib )
223 - vpx? ( gd zlib )
224 - cjk? ( gd zlib )
225 - exif? ( gd zlib )
226 - xpm? ( gd zlib )
227 - gd? ( zlib )
228 - simplexml? ( xml )
229 - soap? ( xml )
230 - wddx? ( xml )
231 - xmlrpc? ( || ( xml iconv ) )
232 - xmlreader? ( xml )
233 - xslt? ( xml )
234 - ldap-sasl? ( ldap )
235 - mhash? ( hash )
236 - phar? ( hash )
237 - recode? ( !imap !mysql !mysqli !libmysqlclient )
238 - libmysqlclient? ( || (
239 - mysql
240 - mysqli
241 - pdo
242 - ) )
243 -
244 - qdbm? ( !gdbm )
245 - readline? ( !libedit )
246 - sharedmem? ( !threads )
247 -"
248 -
249 -PHP_MV="$(ver_cut 1)"
250 -
251 -php_install_ini() {
252 - local phpsapi="${1}"
253 -
254 - # work out where we are installing the ini file
255 - php_set_ini_dir "${phpsapi}"
256 -
257 - # Always install the production INI file, bug 611214.
258 - local phpinisrc="php.ini-production-${phpsapi}"
259 - cp php.ini-production "${phpinisrc}" || die
260 -
261 - # default to /tmp for save_path, bug #282768
262 - sed -e 's|^;session.save_path .*$|session.save_path = "'"${EPREFIX}"'/tmp"|g' -i "${phpinisrc}" || die
263 -
264 - # Set the extension dir
265 - sed -e "s|^extension_dir .*$|extension_dir = ${extension_dir}|g" \
266 - -i "${phpinisrc}" || die
267 -
268 - # Set the include path to point to where we want to find PEAR packages
269 - sed -e 's|^;include_path = ".:/php/includes".*|include_path = ".:'"${EPREFIX}"'/usr/share/php'${PHP_MV}':'"${EPREFIX}"'/usr/share/php"|' -i "${phpinisrc}" || die
270 -
271 - dodir "${PHP_INI_DIR#${EPREFIX}}"
272 - insinto "${PHP_INI_DIR#${EPREFIX}}"
273 - newins "${phpinisrc}" php.ini
274 -
275 - elog "Installing php.ini for ${phpsapi} into ${PHP_INI_DIR#${EPREFIX}}"
276 - elog
277 -
278 - dodir "${PHP_EXT_INI_DIR#${EPREFIX}}"
279 - dodir "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}"
280 -
281 - if use opcache; then
282 - elog "Adding opcache to $PHP_EXT_INI_DIR"
283 - echo "zend_extension=${PHP_DESTDIR}/$(get_libdir)/opcache.so" >> \
284 - "${D}/${PHP_EXT_INI_DIR}"/opcache.ini
285 - dosym "${PHP_EXT_INI_DIR#${EPREFIX}}/opcache.ini" \
286 - "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}/opcache.ini"
287 - fi
288 -
289 - # SAPI-specific handling
290 - if [[ "${sapi}" == "fpm" ]] ; then
291 - einfo "Installing FPM config file php-fpm.conf"
292 - insinto "${PHP_INI_DIR#${EPREFIX}}"
293 - doins sapi/fpm/php-fpm.conf
294 - fi
295 -
296 - dodoc php.ini-{development,production}
297 -}
298 -
299 -php_set_ini_dir() {
300 - PHP_INI_DIR="${EPREFIX}/etc/php/${1}-php${SLOT}"
301 - PHP_EXT_INI_DIR="${PHP_INI_DIR}/ext"
302 - PHP_EXT_INI_DIR_ACTIVE="${PHP_INI_DIR}/ext-active"
303 -}
304 -
305 -src_prepare() {
306 - local patchdir="${WORKDIR}/php-patches-${PATCH_V}"
307 -
308 - eapply "${patchdir}/"
309 -
310 - # Copy test binaries from patches
311 - local ext_src
312 - for ext_src in exif iconv ; do
313 - cp "${patchdir}/${ext_src}/"* "ext/${ext_src}/tests/" || die
314 - done
315 -
316 - # Change PHP branding
317 - # Get the alpha/beta/rc version
318 - sed -re "s|^(PHP_EXTRA_VERSION=\").*(\")|\1-pl${PR/r/}-gentoo\2|g" \
319 - -i configure.in || die "Unable to change PHP branding"
320 -
321 - # Patch PHP to show Gentoo as the server platform
322 - sed -e 's/PHP_UNAME=`uname -a | xargs`/PHP_UNAME=`uname -s -n -r -v | xargs`/g' \
323 - -i configure.in || die "Failed to fix server platform name"
324 -
325 - # Prevent PHP from activating the Apache config,
326 - # as we will do that ourselves
327 - sed -i \
328 - -e "s,-i -a -n php${PHP_MV},-i -n php${PHP_MV},g" \
329 - -e "s,-i -A -n php${PHP_MV},-i -n php${PHP_MV},g" \
330 - configure sapi/apache2filter/config.m4 sapi/apache2handler/config.m4 \
331 - || die
332 -
333 - # Patch PHP to support heimdal instead of mit-krb5
334 - if has_version "app-crypt/heimdal" ; then
335 - sed -e 's|gssapi_krb5|gssapi|g' -i acinclude.m4 \
336 - || die "Failed to fix heimdal libname"
337 - sed -e 's|PHP_ADD_LIBRARY(k5crypto, 1, $1)||g' -i acinclude.m4 \
338 - || die "Failed to fix heimdal crypt library reference"
339 - fi
340 -
341 - eapply_user
342 -
343 - # Force rebuilding aclocal.m4
344 - rm -f aclocal.m4 || die "failed to remove aclocal.m4 in src_prepare"
345 -
346 - mv configure.in configure.ac || die
347 -
348 - eautoreconf
349 -
350 - if [[ ${CHOST} == *-darwin* ]] ; then
351 - # http://bugs.php.net/bug.php?id=48795, bug #343481
352 - sed -i -e '/BUILD_CGI="\\$(CC)/s/CC/CXX/' configure || die
353 - fi
354 -}
355 -
356 -src_configure() {
357 - addpredict /usr/share/snmp/mibs/.index #nowarn
358 - addpredict /var/lib/net-snmp/mib_indexes #nowarn
359 -
360 - PHP_DESTDIR="${EPREFIX}/usr/$(get_libdir)/php${SLOT}"
361 -
362 - # The php-fpm config file wants localstatedir to be ${EPREFIX}/var
363 - # and not the Gentoo default ${EPREFIX}/var/lib. See bug 572002.
364 - local our_conf=(
365 - --prefix="${PHP_DESTDIR}"
366 - --mandir="${PHP_DESTDIR}/man"
367 - --infodir="${PHP_DESTDIR}/info"
368 - --libdir="${PHP_DESTDIR}/lib"
369 - --with-libdir="$(get_libdir)"
370 - --localstatedir="${EPREFIX}/var"
371 - --without-pear
372 - $(use_enable threads maintainer-zts)
373 - )
374 -
375 - our_conf+=(
376 - $(use_enable bcmath bcmath)
377 - $(use_with bzip2 bz2 "${EPREFIX}/usr")
378 - $(use_enable calendar calendar)
379 - $(use_enable coverage gcov)
380 - $(use_enable ctype ctype)
381 - $(use_with curl curl "${EPREFIX}/usr")
382 - $(use_enable xml dom)
383 - $(use_with enchant enchant "${EPREFIX}/usr")
384 - $(use_enable exif exif)
385 - $(use_enable fileinfo fileinfo)
386 - $(use_enable filter filter)
387 - $(use_enable ftp ftp)
388 - $(use_with nls gettext "${EPREFIX}/usr")
389 - $(use_with gmp gmp "${EPREFIX}/usr")
390 - $(use_enable hash hash)
391 - $(use_with mhash mhash "${EPREFIX}/usr")
392 - $(use_with iconv iconv \
393 - $(use elibc_glibc || use elibc_musl || use elibc_FreeBSD || echo "${EPREFIX}/usr"))
394 - $(use_enable intl intl)
395 - $(use_enable ipv6 ipv6)
396 - $(use_enable json json)
397 - $(use_with kerberos kerberos "${EPREFIX}/usr")
398 - $(use_enable xml libxml)
399 - $(use_with xml libxml-dir "${EPREFIX}/usr")
400 - $(use_enable unicode mbstring)
401 - $(use_with crypt mcrypt "${EPREFIX}/usr")
402 - $(use_with mssql mssql "${EPREFIX}/usr")
403 - $(use_with unicode onig "${EPREFIX}/usr")
404 - $(use_with ssl openssl "${EPREFIX}/usr")
405 - $(use_with ssl openssl-dir "${EPREFIX}/usr")
406 - $(use_enable pcntl pcntl)
407 - $(use_enable phar phar)
408 - $(use_enable pdo pdo)
409 - $(use_enable opcache opcache)
410 - $(use_with postgres pgsql "${EPREFIX}/usr")
411 - $(use_enable posix posix)
412 - $(use_with spell pspell "${EPREFIX}/usr")
413 - $(use_with recode recode "${EPREFIX}/usr")
414 - $(use_enable simplexml simplexml)
415 - $(use_enable sharedmem shmop)
416 - $(use_with snmp snmp "${EPREFIX}/usr")
417 - $(use_enable soap soap)
418 - $(use_enable sockets sockets)
419 - $(use_with sqlite sqlite3 "${EPREFIX}/usr")
420 - $(use_with sybase-ct sybase-ct "${EPREFIX}/usr")
421 - $(use_enable sysvipc sysvmsg)
422 - $(use_enable sysvipc sysvsem)
423 - $(use_enable sysvipc sysvshm)
424 - $(use_with tidy tidy "${EPREFIX}/usr")
425 - $(use_enable tokenizer tokenizer)
426 - $(use_enable wddx wddx)
427 - $(use_enable xml xml)
428 - $(use_enable xmlreader xmlreader)
429 - $(use_enable xmlwriter xmlwriter)
430 - $(use_with xmlrpc xmlrpc)
431 - $(use_with xslt xsl "${EPREFIX}/usr")
432 - $(use_enable zip zip)
433 - $(use_with zlib zlib "${EPREFIX}/usr")
434 - $(use_enable debug debug)
435 - )
436 -
437 - # DBA support
438 - if use cdb || use berkdb || use flatfile || use gdbm || use inifile \
439 - || use qdbm ; then
440 - our_conf+=( "--enable-dba${shared}" )
441 - fi
442 -
443 - # DBA drivers support
444 - our_conf+=(
445 - $(use_with cdb cdb)
446 - $(use_with berkdb db4 "${EPREFIX}/usr")
447 - $(use_enable flatfile flatfile)
448 - $(use_with gdbm gdbm "${EPREFIX}/usr")
449 - $(use_enable inifile inifile)
450 - $(use_with qdbm qdbm "${EPREFIX}/usr")
451 - )
452 -
453 - # Support for the GD graphics library
454 - our_conf+=(
455 - $(use_with truetype freetype-dir "${EPREFIX}/usr")
456 - $(use_with truetype t1lib "${EPREFIX}/usr")
457 - $(use_enable cjk gd-jis-conv)
458 - $(use_with gd jpeg-dir "${EPREFIX}/usr")
459 - $(use_with gd png-dir "${EPREFIX}/usr")
460 - $(use_with xpm xpm-dir "${EPREFIX}/usr")
461 - $(use_with vpx vpx-dir "${EPREFIX}/usr")
462 - )
463 - # enable gd last, so configure can pick up the previous settings
464 - our_conf+=( $(use_with gd gd) )
465 -
466 - # IMAP support
467 - if use imap ; then
468 - our_conf+=(
469 - $(use_with imap imap "${EPREFIX}/usr")
470 - $(use_with ssl imap-ssl "${EPREFIX}/usr")
471 - )
472 - fi
473 -
474 - # Interbase/firebird support
475 - our_conf+=( $(use_with firebird interbase "${EPREFIX}/usr") )
476 -
477 - # LDAP support
478 - if use ldap ; then
479 - our_conf+=(
480 - $(use_with ldap ldap "${EPREFIX}/usr")
481 - $(use_with ldap-sasl ldap-sasl "${EPREFIX}/usr")
482 - )
483 - fi
484 -
485 - # MySQL support
486 - local mysqllib="mysqlnd"
487 - local mysqlilib="mysqlnd"
488 - use libmysqlclient && mysqllib="${EPREFIX}/usr"
489 - use libmysqlclient && mysqlilib="${EPREFIX}/usr/bin/mysql_config"
490 -
491 - our_conf+=( $(use_with mysql mysql "${mysqllib}") )
492 - our_conf+=( $(use_with mysqli mysqli "${mysqlilib}") )
493 -
494 - local mysqlsock="${EPREFIX}/var/run/mysqld/mysqld.sock"
495 - if use mysql || use mysqli ; then
496 - our_conf+=( $(use_with mysql mysql-sock "${mysqlsock}") )
497 - fi
498 -
499 - # ODBC support
500 - our_conf+=(
501 - $(use_with odbc unixODBC "${EPREFIX}/usr")
502 - $(use_with iodbc iodbc "${EPREFIX}/usr")
503 - )
504 -
505 - # Oracle support
506 - our_conf+=( $(use_with oci8-instant-client oci8) )
507 -
508 - # PDO support
509 - if use pdo ; then
510 - our_conf+=(
511 - $(use_with mssql pdo-dblib)
512 - $(use_with mysql pdo-mysql "${mysqllib}")
513 - $(use_with postgres pdo-pgsql)
514 - $(use_with sqlite pdo-sqlite "${EPREFIX}/usr")
515 - $(use_with firebird pdo-firebird "${EPREFIX}/usr")
516 - $(use_with odbc pdo-odbc "unixODBC,${EPREFIX}/usr")
517 - $(use_with oci8-instant-client pdo-oci)
518 - )
519 - fi
520 -
521 - # readline/libedit support
522 - our_conf+=(
523 - $(use_with readline readline "${EPREFIX}/usr")
524 - $(use_with libedit libedit "${EPREFIX}/usr")
525 - )
526 -
527 - # Session support
528 - if use session ; then
529 - our_conf+=( $(use_with sharedmem mm "${EPREFIX}/usr") )
530 - else
531 - our_conf+=( $(use_enable session session) )
532 - fi
533 -
534 - # Use pic for shared modules such as apache2's mod_php
535 - our_conf+=( --with-pic )
536 -
537 - # we use the system copy of pcre
538 - # --with-pcre-regex affects ext/pcre
539 - # --with-pcre-dir affects ext/filter and ext/zip
540 - our_conf+=(
541 - --with-pcre-regex="${EPREFIX}/usr"
542 - --with-pcre-dir="${EPREFIX}/usr"
543 - )
544 -
545 - # Catch CFLAGS problems
546 - # Fixes bug #14067.
547 - # Changed order to run it in reverse for bug #32022 and #12021.
548 - replace-cpu-flags "k6*" "i586"
549 -
550 - # Cache the ./configure test results between SAPIs.
551 - our_conf+=( --cache-file="${T}/config.cache" )
552 -
553 - # Support user-passed configuration parameters
554 - our_conf+=( ${EXTRA_ECONF:-} )
555 -
556 - # Support the Apache2 extras, they must be set globally for all
557 - # SAPIs to work correctly, especially for external PHP extensions
558 -
559 - mkdir -p "${WORKDIR}/sapis-build" || die
560 - for one_sapi in $SAPIS ; do
561 - use "${one_sapi}" || continue
562 - php_set_ini_dir "${one_sapi}"
563 -
564 - # The BUILD_DIR variable is used to determine where to output
565 - # the files that autotools creates. This was all originally
566 - # based on the autotools-utils eclass.
567 - BUILD_DIR="${WORKDIR}/sapis-build/${one_sapi}"
568 - cp -a "${S}" "${BUILD_DIR}" || die
569 - cd "${BUILD_DIR}" || die
570 -
571 - local sapi_conf=(
572 - --with-config-file-path="${PHP_INI_DIR}"
573 - --with-config-file-scan-dir="${PHP_EXT_INI_DIR_ACTIVE}"
574 - )
575 -
576 - for sapi in $SAPIS ; do
577 - case "$sapi" in
578 - cli|cgi|embed|fpm)
579 - if [[ "${one_sapi}" == "${sapi}" ]] ; then
580 - sapi_conf+=( "--enable-${sapi}" )
581 - if [[ "fpm" == "${sapi}" ]] ; then
582 - sapi_conf+=(
583 - $(use_with acl fpm-acl)
584 - $(use_with systemd fpm-systemd)
585 - )
586 - fi
587 - else
588 - sapi_conf+=( "--disable-${sapi}" )
589 - fi
590 - ;;
591 -
592 - apache2)
593 - if [[ "${one_sapi}" == "${sapi}" ]] ; then
594 - sapi_conf+=( --with-apxs2="${EPREFIX}/usr/bin/apxs" )
595 - else
596 - sapi_conf+=( --without-apxs2 )
597 - fi
598 - ;;
599 - esac
600 - done
601 -
602 - # Construct the $myeconfargs array by concatenating $our_conf
603 - # (the common args) and $sapi_conf (the SAPI-specific args).
604 - local myeconfargs=( "${our_conf[@]}" )
605 - myeconfargs+=( "${sapi_conf[@]}" )
606 -
607 - pushd "${BUILD_DIR}" > /dev/null || die
608 - econf "${myeconfargs[@]}"
609 - popd > /dev/null || die
610 - done
611 -}
612 -
613 -src_compile() {
614 - # snmp seems to run during src_compile, too (bug #324739)
615 - addpredict /usr/share/snmp/mibs/.index #nowarn
616 - addpredict /var/lib/net-snmp/mib_indexes #nowarn
617 -
618 - for sapi in ${SAPIS} ; do
619 - if use "${sapi}"; then
620 - cd "${WORKDIR}/sapis-build/$sapi" || \
621 - die "Failed to change dir to ${WORKDIR}/sapis-build/$1"
622 - emake
623 - fi
624 - done
625 -}
626 -
627 -src_install() {
628 - # see bug #324739 for what happens when we don't have that
629 - addpredict /usr/share/snmp/mibs/.index #nowarn
630 -
631 - # grab the first SAPI that got built and install common files from there
632 - local first_sapi=""
633 - for sapi in $SAPIS ; do
634 - if use $sapi ; then
635 - first_sapi=$sapi
636 - break
637 - fi
638 - done
639 -
640 - # Makefile forgets to create this before trying to write to it...
641 - dodir "${PHP_DESTDIR#${EPREFIX}}/bin"
642 -
643 - # Install php environment (without any sapis)
644 - cd "${WORKDIR}/sapis-build/$first_sapi" || die
645 - emake INSTALL_ROOT="${D}" \
646 - install-build install-headers install-programs
647 -
648 - local extension_dir="$("${ED}/${PHP_DESTDIR#${EPREFIX}}/bin/php-config" --extension-dir)"
649 -
650 - # Create the directory where we'll put version-specific php scripts
651 - keepdir "/usr/share/php${PHP_MV}"
652 -
653 - local sapi="", file=""
654 - local sapi_list=""
655 -
656 - for sapi in ${SAPIS}; do
657 - if use "${sapi}" ; then
658 - einfo "Installing SAPI: ${sapi}"
659 - cd "${WORKDIR}/sapis-build/${sapi}" || die
660 -
661 - if [[ "${sapi}" == "apache2" ]] ; then
662 - # We're specifically not using emake install-sapi as libtool
663 - # may cause unnecessary relink failures (see bug #351266)
664 - insinto "${PHP_DESTDIR#${EPREFIX}}/apache2/"
665 - newins ".libs/libphp5$(get_libname)" \
666 - "libphp${PHP_MV}$(get_libname)"
667 - keepdir "/usr/$(get_libdir)/apache2/modules"
668 - else
669 - # needed each time, php_install_ini would reset it
670 - local dest="${PHP_DESTDIR#${EPREFIX}}"
671 - into "${dest}"
672 - case "$sapi" in
673 - cli)
674 - source="sapi/cli/php"
675 - ;;
676 - cgi)
677 - source="sapi/cgi/php-cgi"
678 - ;;
679 - fpm)
680 - source="sapi/fpm/php-fpm"
681 - ;;
682 - embed)
683 - source="libs/libphp${PHP_MV}$(get_libname)"
684 - ;;
685 - *)
686 - die "unhandled sapi in src_install"
687 - ;;
688 - esac
689 -
690 - if [[ "${source}" == *"$(get_libname)" ]]; then
691 - dolib.so "${source}"
692 - else
693 - dobin "${source}"
694 - local name="$(basename ${source})"
695 - dosym "${dest}/bin/${name}" "/usr/bin/${name}${SLOT}"
696 - fi
697 - fi
698 -
699 - php_install_ini "${sapi}"
700 -
701 - # construct correct SAPI string for php-config
702 - # thanks to ferringb for the bash voodoo
703 - if [[ "${sapi}" == "apache2" ]]; then
704 - sapi_list="${sapi_list:+${sapi_list} }apache2handler"
705 - else
706 - sapi_list="${sapi_list:+${sapi_list} }${sapi}"
707 - fi
708 - fi
709 - done
710 -
711 - # Installing opcache module
712 - if use opcache ; then
713 - into "${PHP_DESTDIR#${EPREFIX}}"
714 - dolib.so "modules/opcache$(get_libname)"
715 - fi
716 -
717 - # Install env.d files
718 - newenvd "${FILESDIR}/20php5-envd" "20php${SLOT}"
719 - sed -e "s|/lib/|/$(get_libdir)/|g" -i "${ED}/etc/env.d/20php${SLOT}" || die
720 - sed -e "s|php5|php${SLOT}|g" -i "${ED}/etc/env.d/20php${SLOT}" || die
721 -
722 - # set php-config variable correctly (bug #278439)
723 - sed -e "s:^\(php_sapis=\)\".*\"$:\1\"${sapi_list}\":" -i \
724 - "${ED}/usr/$(get_libdir)/php${SLOT}/bin/php-config" || die
725 -
726 - if use fpm ; then
727 - if use systemd; then
728 - systemd_newunit "${FILESDIR}/php-fpm_at.service" \
729 - "php-fpm@${SLOT}.service"
730 - else
731 - systemd_newunit "${FILESDIR}/php-fpm_at-simple.service" \
732 - "php-fpm@${SLOT}.service"
733 - fi
734 - fi
735 -}
736 -
737 -src_test() {
738 - echo ">>> Test phase [test]: ${CATEGORY}/${PF}"
739 - PHP_BIN="${WORKDIR}/sapis-build/cli/sapi/cli/php"
740 - if [[ ! -x "${PHP_BIN}" ]] ; then
741 - ewarn "Test phase requires USE=cli, skipping"
742 - return
743 - else
744 - export TEST_PHP_EXECUTABLE="${PHP_BIN}"
745 - fi
746 -
747 - if [[ -x "${WORKDIR}/sapis/cgi/php-cgi" ]] ; then
748 - export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis/cgi/php-cgi"
749 - fi
750 -
751 - REPORT_EXIT_STATUS=1 "${TEST_PHP_EXECUTABLE}" -n -d \
752 - "session.save_path=${T}" \
753 - "${WORKDIR}/sapis-build/cli/run-tests.php" -n -q -d \
754 - "session.save_path=${T}"
755 -
756 - for name in ${EXPECTED_TEST_FAILURES}; do
757 - mv "${name}.out" "${name}.out.orig" 2>/dev/null || die
758 - done
759 -
760 - local failed="$(find -name '*.out')"
761 - if [[ ${failed} != "" ]] ; then
762 - ewarn "The following test cases failed unexpectedly:"
763 - for name in ${failed}; do
764 - ewarn " ${name/.out/}"
765 - done
766 - else
767 - einfo "No unexpected test failures, all fine"
768 - fi
769 -
770 - if [[ ${PHP_SHOW_UNEXPECTED_TEST_PASS} == "1" ]] ; then
771 - local passed=""
772 - for name in ${EXPECTED_TEST_FAILURES}; do
773 - [[ -f "${name}.diff" ]] && continue
774 - passed="${passed} ${name}"
775 - done
776 - if [[ ${passed} != "" ]] ; then
777 - einfo "The following test cases passed unexpectedly:"
778 - for name in ${passed}; do
779 - ewarn " ${passed}"
780 - done
781 - else
782 - einfo "None of the known-to-fail tests passed, all fine"
783 - fi
784 - fi
785 -}
786 -
787 -pkg_postinst() {
788 - # Output some general info to the user
789 - if use apache2 ; then
790 - elog
791 - elog "To enable PHP in apache, you will need to add \"-D PHP\" to"
792 - elog "your apache2 command. OpenRC users can append that string to"
793 - elog "APACHE2_OPTS in /etc/conf.d/apache2."
794 - elog
795 - elog "The apache module configuration file 70_mod_php.conf is"
796 - elog "provided (and maintained) by eselect-php."
797 - elog
798 - fi
799 -
800 - # Create the symlinks for php
801 - for m in ${SAPIS}; do
802 - [[ ${m} == 'embed' ]] && continue;
803 - if use $m ; then
804 - local ci=$(eselect php show $m)
805 - if [[ -z $ci ]]; then
806 - eselect php set $m php${SLOT} || die
807 - einfo "Switched ${m} to use php:${SLOT}"
808 - einfo
809 - elif [[ $ci != "php${SLOT}" ]] ; then
810 - elog "To switch $m to use php:${SLOT}, run"
811 - elog " eselect php set $m php${SLOT}"
812 - elog
813 - fi
814 - fi
815 - done
816 -
817 - # Remove dead symlinks for SAPIs that were just disabled. For
818 - # example, if the user has the cgi SAPI enabled, then he has an
819 - # eselect-php symlink for it. If he later reinstalls PHP with
820 - # USE="-cgi", that symlink will break. This call to eselect is
821 - # supposed to remove that dead link per bug 572436.
822 - eselect php cleanup || die
823 -
824 - if ! has "php${SLOT/./-}" ${PHP_TARGETS}; then
825 - elog "To build extensions for this version of PHP, you will need to"
826 - elog "add php${SLOT/./-} to your PHP_TARGETS USE_EXPAND variable."
827 - elog
828 - fi
829 -
830 - # Warn about the removal of PHP_INI_VERSION if the user has it set.
831 - if [[ -n "${PHP_INI_VERSION}" ]]; then
832 - ewarn 'The PHP_INI_VERSION variable has been phased out. You may'
833 - ewarn 'remove it from your configuration at your convenience. See'
834 - ewarn
835 - ewarn ' https://bugs.gentoo.org/611214'
836 - ewarn
837 - ewarn 'for more information.'
838 - fi
839 -
840 - elog "For details on how version slotting works, please see"
841 - elog "the wiki:"
842 - elog
843 - elog " https://wiki.gentoo.org/wiki/PHP"
844 - elog
845 -}
846 -
847 -pkg_postrm() {
848 - # This serves two purposes. First, if we have just removed the last
849 - # installed version of PHP, then this will remove any dead symlinks
850 - # belonging to eselect-php. Second, if a user upgrades slots from
851 - # (say) 5.6 to 7.0 and depcleans the old slot, then this will update
852 - # his existing symlinks to point to the new 7.0 installation. The
853 - # latter is bug 432962.
854 - #
855 - # Note: the eselect-php package may not be installed at this point,
856 - # so we can't die() if this command fails.
857 - eselect php cleanup
858 -}
859
860 diff --git a/profiles/package.mask b/profiles/package.mask
861 index 8fb933ce95d..25a1eb415d3 100644
862 --- a/profiles/package.mask
863 +++ b/profiles/package.mask
864 @@ -771,12 +771,6 @@ dev-libs/gmp:3
865 # Please migrate to sys-apps/man-db.
866 sys-apps/man
867
868 -# Brian Evans <grknight@g.o> (2019-10-01)
869 -# End of life. Please upgrade.
870 -# Removal in 90 days. Bug 651784
871 -dev-lang/php:5.6
872 -virtual/httpd-php:5.6
873 -
874 # Stefan Strogin <steils@g.o> (2019-09-27)
875 # Requires >=dev-lang/lua-5.3 which is masked
876 >=dev-util/bam-0.5.0