diff options
author | Ole Markus With <olemarkus@gentoo.org> | 2013-04-25 11:00:29 +0000 |
---|---|---|
committer | Ole Markus With <olemarkus@gentoo.org> | 2013-04-25 11:00:29 +0000 |
commit | 4d9c693b92ab51a3238cf55d67212837fa55461f (patch) | |
tree | 96d795040781a4166592dff9ae91767529b2230e /dev-lang/php | |
parent | Automake fix for #466950 (diff) | |
download | historical-4d9c693b92ab51a3238cf55d67212837fa55461f.tar.gz historical-4d9c693b92ab51a3238cf55d67212837fa55461f.tar.bz2 historical-4d9c693b92ab51a3238cf55d67212837fa55461f.zip |
Bump php 5.5 beta
Package-Manager: portage-2.1.11.55/cvs/Linux x86_64
Manifest-Sign-Key: 0xC4A92BF5
Diffstat (limited to 'dev-lang/php')
-rw-r--r-- | dev-lang/php/ChangeLog | 7 | ||||
-rw-r--r-- | dev-lang/php/Manifest | 28 | ||||
-rw-r--r-- | dev-lang/php/php-5.5.0_beta4.ebuild | 771 |
3 files changed, 790 insertions, 16 deletions
diff --git a/dev-lang/php/ChangeLog b/dev-lang/php/ChangeLog index ab50c0ad2c50..0153ab2572e0 100644 --- a/dev-lang/php/ChangeLog +++ b/dev-lang/php/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for dev-lang/php # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/ChangeLog,v 1.705 2013/04/13 20:46:03 ago Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/ChangeLog,v 1.706 2013/04/25 11:00:17 olemarkus Exp $ + +*php-5.5.0_beta4 (25 Apr 2013) + + 25 Apr 2013; Ole Markus With <olemarkus@gentoo.org> +php-5.5.0_beta4.ebuild: + Bump php 5.5 beta 13 Apr 2013; Agostino Sarubbo <ago@gentoo.org> php-5.3.23.ebuild, php-5.4.13.ebuild: diff --git a/dev-lang/php/Manifest b/dev-lang/php/Manifest index 1659265fff6c..89ba2548dfc5 100644 --- a/dev-lang/php/Manifest +++ b/dev-lang/php/Manifest @@ -1,5 +1,5 @@ -----BEGIN PGP SIGNED MESSAGE----- -Hash: SHA512 +Hash: SHA256 AUX 20php5-envd 145 SHA256 efaae9e6ae5f7010e073c2ab6d8a9dda009f0707c7d7b0c027e142c94f7041a4 SHA512 581aa86479e3cd584ee1bc6dc6d4a135fe8ec343fe5519566d728d81f7018cfb23658bd0c0368951d380982c75adbb4f45acf3c146868aaf4e4ec8e9f2fad1ce WHIRLPOOL b9cfe0e80ba437bbc6008223c268bdafcde306ba8083dce96815804f3e1ec0937706e0db091149785a0076a6c6eaab8f7dff28578b706e84b4bb4e67850a4ecd AUX 70_mod_php5.conf-apache2 348 SHA256 5bb8a45570582b4389a7d3feea0398e1c13ed4ced96e559b9406ed8c965dea8c SHA512 c74ec09c3c4124a15e14ece4bb769bb889466160cc0878ca3d55d5afc30fd4c05673c40428b75be669f72e82ba29f60ed19767caca77bba8adc12aae1c83f6f3 WHIRLPOOL fd503ec904a3853b90f8f4cc2042cf9014fdb1383a508d22e680559009b5b1e0beb5a09909a393e53868a64712c63e35642915787fa4176af07cb594adedb441 @@ -34,6 +34,7 @@ DIST php-5.4.13.tar.bz2 11545777 SHA256 f80c9452f63a6d259d4edd5228be2136da98122f DIST php-5.4.14.tar.bz2 11961015 SHA256 5450f3843bc651eb3fb00601f0cce1930aaaf65c7c966c02fe4a46f9c81be20a SHA512 7279e7e621440038dca6a2086963fc0852260716aeb6cefe952ba1dade1797b2eaf8eeed3b26d053015079135ee5e8cc6bacd9184b1a9dc77b36169fe75448f2 WHIRLPOOL 9f4b8985a5559bbd7c05784512c290959da52626c8a622c9a1316e1c1ff1757a9abd67f7f2a7ecb75ee65d69640cb75ca2a9e7cbb72842484ef285972a87b187 DIST php-5.4.8.tar.bz2 11056057 SHA256 d02810b7949938ee7190116e7483e1a06b3fa8373d3bbc0ea65a41265afce79f SHA512 e04ee08e7d1b6f80183846206d02576ad22ea3f41e956bab970344b195f1d2267f1ff69439988cea7084c18576d7855383e48094bdb7684d43cb0f78e4a5e7b8 WHIRLPOOL 963153d85236bd105cbf11a89dd0db11e590cc292bb499abaa9271dbb47eeb124ef011af9561cb5569840d32130934c70cd8ebb4d619147892044ab8c3be09bd DIST php-5.5.0beta3.tar.bz2 12259497 SHA256 1a35e48c561a1bc69281657857ac5c8f218027bcd58700d73f44804e24bc892f SHA512 55ce7ef0ce3d9ebf49e5a5dd1bc30d2df25fc729b02ea197e51c07a9a5c741ceafffda418229e189714f157a7b4f11c6741733c785a56ed5bf3f0a4ada3fe2c2 WHIRLPOOL ecd42f945e5d31945fde42c70852310de1bc46334275fe3d78117bb8424c53d14f882194d661221bf6f143034bea8b8989bfc18b5b0153d523c9f8767285e30d +DIST php-5.5.0beta4.tar.bz2 12248733 SHA256 9d1a0941ce9f933695cfaf6a0e7e9032adc784848f528c8b14569ddfe0fcfde4 SHA512 7e046584962bbd1ad3a8e9ef7f64fee0a9e484e97c2127c8573f033223c6d6560a8855cad5231e06158c868c9f489a9e00b41f8df26ef39cfdffd8880f7e5da1 WHIRLPOOL b2b816f770a63ecb8ebef68eaf20338e8c30b39357041534263ec37a41f327d254b2df2b41a51b920366c365a2cd2c7f4d0fa219535e8746ea84b6a894a8c3ff DIST php-patchset-5.3-r0.tar.bz2 7368 SHA256 1a67b34a681dea33ea38f0ffc32b70a78b4c5dc1c3603d1bba31bb130d803ef7 SHA512 765b0cf56a3e63ded4ad1d1ba67567881ad06bdc2814cc07004fa338f38fd69078819c7463d2c55e00805c8f33fa925b94228bf7bc3d223acc33c6cff540024c WHIRLPOOL 59e18b33e11d968fac2a4571173121bf8141bb2f1eab62192e15bc59e351d3ab973f04343b447681d8a2adddf0844edb8a481d027bfc14c7e1fd8222169094ec DIST php-patchset-5.3.18-r0.tar.bz2 7360 SHA256 8e7d449a4ab50dd8da241f2992fdaee012eafe4da6c66609231cff68d84c5c9f SHA512 625f456649964a959c7aa399c6c4fbeff8dd0b45372153819d42b447069e78cce99b4b6c30d89a64b211d230e17ef28e99d5e3b9055dd59e19b8103337de8d09 WHIRLPOOL cb1ae11173fa6d0a0f26a313d036f6f2109bc704531c5db76a584cc243b5f16ccff3c5e0c943196b5f13a7603e222c2f2c0eb393d754faf66fa5d54e5f627fde DIST php-patchset-5.4-2.tar.bz2 5824 SHA256 4a47f4d31f50a244f85349486cdb3474cf315562e097ed4c116c2b9b5730ecef SHA512 3c2523458a627373da7acb93fb2cd621f50b19fe2ba1d30beb62eeaaa39045262b917cfd0b631046fec9c8027cfa99bd0426a079ab45eb172b21d25d6e085dde WHIRLPOOL fe4f015e2f0dc66cc23ef16fb5bb33117952593ae0770d4bcd37ecc1c431cbcc7874189d265696305c60b4e395e7ce902667e38203db46867304868271affdea @@ -45,23 +46,20 @@ EBUILD php-5.4.13.ebuild 24050 SHA256 c4eb0a963547743d628ccb906a2e947604581aca3f EBUILD php-5.4.14.ebuild 22098 SHA256 7e18b169780b41bf512fd9f72c972430436ec6bf86d0f1641d77597939a8a165 SHA512 08d08b5887df700d956eff8464126923fda7a76d0bf2fabd41d23a2c2afc9fb6f0e4bb40a4b5012db7613247c5920f63b4f5adc3bdfd398f5c7a7e0edb068c6f WHIRLPOOL 8788b867020a8ddcb16c833ab0eda69f80e1c4fcd8cf3e69e0e1afa038255b98dfee0c163d6a614b2749e3f15ca17be04e85091378177242b32c82c9dfdc19b9 EBUILD php-5.4.8.ebuild 24439 SHA256 aa479fbd46229b6a59941b2e412db808f99946f42e618c782d02b705ec3c389f SHA512 62c30f24f869f38ec8231fef2c1191bc52a463568423c001c454b0e0d3f00732b62d58180d1ef5401d5c88a38e4bda4ff288df7f4f1f8cac1f37e614554870e3 WHIRLPOOL 4032c32caa2d7c8928ff7f66646363a29145fee4ccfe1b096e48317dde450003a779fc06f06cabdb74a46ea2b909f429c2a54ddfd4d8ef0b6826faa63366868b EBUILD php-5.5.0_beta3.ebuild 21960 SHA256 54a6c14363b857f71a2c8853ca180c374b88a5602a48c30805bf859aa8416cac SHA512 594233873ff067a3ee446f4d2be23a85d691637355b5fb11231545248793489cd1d6f161becc153673c2cb9c5666a02ffc1161d5d80b13db509b6d380960ef52 WHIRLPOOL 1754810b1d28b8a76c1e153d6ae538979d7988c3387bec3048624ada61257bd42841d7a658c098ac1b810a29fd31543b40927902ef8817d8adb791c823237c6a -MISC ChangeLog 7428 SHA256 367857283365da66137c98df52ef436898d2f94ec34ae187ccff5a0f34a52848 SHA512 d63d74ea9c015758510c0eaaf6554d93e6c484709f1fa5475373f4056638a60cffbacbdf2b25b6e1a17ed5b0c10f8a39439b705041f333f1971ca26088acadc7 WHIRLPOOL 4d2810a7eb6882885a1899ab77ca70e473836325daf9f2338799ce3202551a2b8238167d2f4915b365e96f7436ad05d23ebcd25a35e1ae09ec070c088e53cda3 +EBUILD php-5.5.0_beta4.ebuild 21891 SHA256 b3ccbfe036c06a81fa6e7d350f192007a7d77c2e9947cc41d64a346642124f1a SHA512 b474d02ad53d8ab12e6cf4483a7e3b8c089381092f838d4799ece440adf2e662af94ee3f34d5e61b095aec4284be5490506eb26f83e29f81501296a96bd007eb WHIRLPOOL 6e334d7220471ab6ffdc33794c7bb15d0f93b8891b31adfce97c01534b35411e59357d982c2dbdcb101c02988cd6893aadc85c008d0a3b4697fc7bd91ffe389f +MISC ChangeLog 7566 SHA256 1084eb0ab3721816c6266376476e6044c886f5eb5bf6f417a864149e3b2a7320 SHA512 7c8b08f54011b59e29af7947d45cd8b1e92bc98ec7ec66fba2a17fbfb8d01140da73593f6856db6b867ea24b3bcd179319eca11535ed4428938a92feb092d489 WHIRLPOOL 886fd05aea0933df3315d7f9b1b137685a0d55be07c587849ed58c5fba37cd8ac60f1fedd0558065b2720ec00b91875e34a1ad04aff46d7c70f63b1edafa694c MISC ChangeLog-2012 108488 SHA256 c2eea36502d34eadc7995d546f78aaa553ba07beeb51ea738715ad7f2e51b08d SHA512 eb25224993eff1ea42ea133302991a3ffad3adda0bc524cfa4fae49574230a8e65b35b08750d780c11cc9c152435fadbf2c416241fac28dcbb025e060e96cd7a WHIRLPOOL 82f627853fa961f3f3707fb2c8757acbc8fc644e89121d78703b40ff0f668aa7d0f1aa26c77f8f503e4f6da22ed865e4cb7c02d5d112c89488b12aa6b0d80568 MISC metadata.xml 1600 SHA256 f69cee357d251547d4e97cbb562ad6ab6b78383b4bcd8e183523b29a63c2f214 SHA512 2c7f74d61e6b9e86f9ece5981a26868316c4dc0ad759cc4eeacece9e33854d33d6265b4ee2d00e2e36baad6ec09ee916114f3dde6ded9cc9e45bef0c560e335b WHIRLPOOL dc007ba84a95d047f01d789302246033363bc412ebbdb75fe50e67088e91356c0c8cee76f2da59f771bbf99ad3f0113860852c82ac0ae5ad1c2a21a380e3ae0b -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (GNU/Linux) -iQIcBAEBCgAGBQJRacNzAAoJELp701BxlEWf4RcP/Rav1R+N85dX3vWPc4QxxYxO -sx3Q6Fjux2Iil4ZQn8K3qyBNar1OsODKTp+qKoC/SQtkjaT9TCblz78ydkBsrua2 -cGkVygLCTs1AHqi6fSomQlgPjzx9LjN5MxvfjU//TOLdduDp/SxUv02vnziGjEp9 -ayEIbV4lcyKu+Q4lhBIjKnfKPDqPJiJj4WoRIknN+5yuEQrLW7xK7SVe5/5VNnHs -jqPYYVauCdBu2eXM1bfwFX8htFufrpw+HPXjz4WTjK4bXVirSDUGjZIOjdgFfHWj -gzqdKjM51g+9Bth1YGIj9HNQiiAxyL7OGdAYLvO4PThJaf6LIi5dst/Rsrj0lCjv -Ul49stpmdHRMCMNUn1dr0C+fAXWwcGHLJaad6UAWdiG7ekrYrqdCFTPpoWyilAb4 -gxrdPmMyNbWAcZ1D/QC/FgAS0FgSBUmgoQua+pK13DPnnpObfhClcomXwc4LPQvk -bPa35ZM+8i8FjYeYbwq+1ONvPtsGxhdtt1+BmJ/EMtHU7Cd3RK/u8uOl+30gsNX2 -NY1NzRe4QSICqegvYElvDh1oD0itv+dFwrsCJ59wZqcnRvm9Anlg7Y74UZCx7AH4 -pEP3hlljmHTveBkTozdV51BT3A8KoxI3saj0ErtzDoCrj1wXthTwVx7Rk5bjHOCt -JizKY0tpeGtpN3w1Pl/+ -=om8S +iQF8BAEBCABmBQJReQzEXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w +ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQyOEZEMjNGNzBENkE5N0Q2Q0ZFMkFDNDA2 +QkFCNEFFNUM0QTkyQkY1AAoJEGurSuXEqSv10AMH+wVx7V9TK5tyYGEAwEZJ1ZQa +yBveCvcp/mdqi0TM+DCHmaP0ZOAqxeXjoNIXQ5gYkl0Ns3SxcGxTmYOLEilZBtTR +XJ7KfX8zBD3wwhF0VLuTXBznhg6UZoIPtJ4H4qnAVY4rV7h57VbVjMFO64uUdKhO +OkLdh0VFA3gsO+Zy3j5IS4tZ89LyPr9Dffr6x0qFKTCLh6dv80wCVTB1qW0ZJWKm +kBPFzS/Q9QN9zCV9KyAm8aO5i8Zc0o6AJu7iomzYXo2OQJAykEBnbN1hc9/8KBmQ +a6yqWNYlhhEEbTjZXnN/Q41mzmGKHLSP664xtIEZkmWIFPF+aOM5mGj9X0laUNE= +=iDLW -----END PGP SIGNATURE----- diff --git a/dev-lang/php/php-5.5.0_beta4.ebuild b/dev-lang/php/php-5.5.0_beta4.ebuild new file mode 100644 index 000000000000..3383b72d29e5 --- /dev/null +++ b/dev-lang/php/php-5.5.0_beta4.ebuild @@ -0,0 +1,771 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/php-5.5.0_beta4.ebuild,v 1.1 2013/04/25 11:00:17 olemarkus Exp $ + +EAPI=5 + +inherit eutils autotools flag-o-matic versionator depend.apache apache-module db-use libtool + +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-freebsd ~amd64-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos" + +function php_get_uri () +{ + case "${1}" in + "php-pre") + echo "http://downloads.php.net/dsp/${2}" + ;; + "php") + echo "http://www.php.net/distributions/${2}" + ;; + "olemarkus") + echo "http://dev.gentoo.org/~olemarkus/php/${2}" + ;; + "gentoo") + echo "mirror://gentoo/${2}" + ;; + *) + die "unhandled case in php_get_uri" + ;; + esac +} + +PHP_MV="$(get_major_version)" +SLOT="$(get_version_component_range 1-2)" + +# alias, so we can handle different types of releases (finals, rcs, alphas, +# betas, ...) w/o changing the whole ebuild +PHP_PV="${PV/_rc/RC}" +PHP_PV="${PHP_PV/_alpha/alpha}" +PHP_PV="${PHP_PV/_beta/beta}" +PHP_RELEASE="php" +[[ ${PV} == ${PV/_alpha/} ]] || PHP_RELEASE="php-pre" +[[ ${PV} == ${PV/_beta/} ]] || PHP_RELEASE="php-pre" +[[ ${PV} == ${PV/_rc/} ]] || PHP_RELEASE="php-pre" +PHP_P="${PN}-${PHP_PV}" + +PHP_SRC_URI="$(php_get_uri "${PHP_RELEASE}" "${PHP_P}.tar.bz2")" + +PHP_FPM_CONF_VER="1" + +SRC_URI="${PHP_SRC_URI}" + +DESCRIPTION="The PHP language runtime engine: CLI, CGI, FPM/FastCGI, Apache2 and embed SAPIs." +HOMEPAGE="http://php.net/" +LICENSE="PHP-3" + +S="${WORKDIR}/${PHP_P}" + +# We can build the following SAPIs in the given order +SAPIS="embed cli cgi fpm apache2" + +# SAPIs and SAPI-specific USE flags (cli SAPI is default on): +IUSE="${IUSE} + ${SAPIS/cli/+cli} + threads" + +IUSE="${IUSE} bcmath berkdb bzip2 calendar cdb cjk + crypt +ctype curl debug + enchant exif frontbase +fileinfo +filter firebird + flatfile ftp gd gdbm gmp +hash +iconv imap inifile + intl iodbc ipv6 +json kerberos ldap ldap-sasl libedit mhash + mssql mysql libmysqlclient mysqli nls + oci8-instant-client odbc +opcache pcntl pdo +phar +posix postgres qdbm + readline recode selinux +session sharedmem + +simplexml snmp soap sockets spell sqlite ssl + sybase-ct sysvipc tidy +tokenizer truetype unicode wddx + +xml xmlreader xmlwriter xmlrpc xpm xsl zip zlib" + +DEPEND=" + >=app-admin/eselect-php-0.7.0[apache2?,fpm?] + >=dev-libs/libpcre-8.32[unicode] + apache2? ( www-servers/apache[threads=] ) + berkdb? ( =sys-libs/db-4* ) + bzip2? ( app-arch/bzip2 ) + cdb? ( || ( dev-db/cdb dev-db/tinycdb ) ) + cjk? ( !gd? ( + virtual/jpeg + media-libs/libpng:0= + sys-libs/zlib + ) ) + crypt? ( >=dev-libs/libmcrypt-2.4 ) + curl? ( >=net-misc/curl-7.10.5 ) + enchant? ( app-text/enchant ) + exif? ( !gd? ( + virtual/jpeg + media-libs/libpng:0= + sys-libs/zlib + ) ) + firebird? ( dev-db/firebird ) + gd? ( virtual/jpeg media-libs/libpng:0= sys-libs/zlib ) + gdbm? ( >=sys-libs/gdbm-1.8.0 ) + gmp? ( >=dev-libs/gmp-4.1.2 ) + iconv? ( virtual/libiconv ) + imap? ( virtual/imap-c-client[ssl=] ) + intl? ( dev-libs/icu:= ) + iodbc? ( dev-db/libiodbc ) + kerberos? ( virtual/krb5 ) + ldap? ( >=net-nds/openldap-1.2.11 ) + ldap-sasl? ( dev-libs/cyrus-sasl >=net-nds/openldap-1.2.11 ) + libedit? ( || ( sys-freebsd/freebsd-lib dev-libs/libedit ) ) + mssql? ( dev-db/freetds[mssql] ) + libmysqlclient? ( + mysql? ( virtual/mysql ) + mysqli? ( >=virtual/mysql-4.1 ) + ) + nls? ( sys-devel/gettext ) + oci8-instant-client? ( dev-db/oracle-instantclient-basic ) + odbc? ( >=dev-db/unixODBC-1.8.13 ) + postgres? ( dev-db/postgresql-base ) + qdbm? ( dev-db/qdbm ) + readline? ( sys-libs/readline ) + recode? ( app-text/recode ) + sharedmem? ( dev-libs/mm ) + simplexml? ( >=dev-libs/libxml2-2.6.8 ) + snmp? ( >=net-analyzer/net-snmp-5.2 ) + soap? ( >=dev-libs/libxml2-2.6.8 ) + spell? ( >=app-text/aspell-0.50 ) + sqlite? ( >=dev-db/sqlite-3.7.6.3 ) + ssl? ( >=dev-libs/openssl-0.9.7 ) + sybase-ct? ( dev-db/freetds ) + tidy? ( app-text/htmltidy ) + truetype? ( + =media-libs/freetype-2* + >=media-libs/t1lib-5.0.0 + !gd? ( + virtual/jpeg media-libs/libpng:0= sys-libs/zlib ) + ) + unicode? ( dev-libs/oniguruma ) + wddx? ( >=dev-libs/libxml2-2.6.8 ) + xml? ( >=dev-libs/libxml2-2.6.8 ) + xmlrpc? ( >=dev-libs/libxml2-2.6.8 virtual/libiconv ) + xmlreader? ( >=dev-libs/libxml2-2.6.8 ) + xmlwriter? ( >=dev-libs/libxml2-2.6.8 ) + xpm? ( + x11-libs/libXpm + virtual/jpeg + media-libs/libpng:0= sys-libs/zlib + ) + xsl? ( dev-libs/libxslt >=dev-libs/libxml2-2.6.8 ) + zip? ( sys-libs/zlib ) + zlib? ( sys-libs/zlib ) + virtual/mta +" + +php="=${CATEGORY}/${PF}" + +REQUIRED_USE=" + truetype? ( gd ) + cjk? ( gd ) + exif? ( gd ) + + xpm? ( gd ) + gd? ( zlib ) + simplexml? ( xml ) + soap? ( xml ) + wddx? ( xml ) + xmlrpc? ( || ( xml iconv ) ) + xmlreader? ( xml ) + xsl? ( xml ) + ldap-sasl? ( ldap ) + mhash? ( hash ) + phar? ( hash ) + libmysqlclient? ( || ( + mysql + mysqli + pdo + ) ) + + qdbm? ( !gdbm ) + readline? ( !libedit ) + recode? ( !imap !mysql !mysqli ) + sharedmem? ( !threads ) + + !cli? ( !cgi? ( !fpm? ( !apache2? ( !embed? ( cli ) ) ) ) )" + +RDEPEND="${DEPEND}" + +RDEPEND="${RDEPEND} fpm? ( selinux? ( sec-policy/selinux-phpfpm ) )" + +DEPEND="${DEPEND} + sys-devel/flex + >=sys-devel/m4-1.4.3 + >=sys-devel/libtool-1.5.18" + +# Allow users to install production version if they want to + +case "${PHP_INI_VERSION}" in + production|development) + ;; + *) + PHP_INI_VERSION="development" + ;; +esac + +PHP_INI_UPSTREAM="php.ini-${PHP_INI_VERSION}" +PHP_INI_FILE="php.ini" + +want_apache + +pkg_setup() { + depend.apache_pkg_setup +} + +php_install_ini() { + local phpsapi="${1}" + + # work out where we are installing the ini file + php_set_ini_dir "${phpsapi}" + + local phpinisrc="${PHP_INI_UPSTREAM}-${phpsapi}" + cp "${PHP_INI_UPSTREAM}" "${phpinisrc}" + + # default to /tmp for save_path, bug #282768 + sed -e 's|^;session.save_path .*$|session.save_path = "'"${EPREFIX}"'/tmp"|g' -i "${phpinisrc}" + + # Set the extension dir + sed -e "s|^extension_dir .*$|extension_dir = ${extension_dir}|g" -i "${phpinisrc}" + + # Set the include path to point to where we want to find PEAR packages + sed -e 's|^;include_path = ".:/php/includes".*|include_path = ".:'"${EPREFIX}"'/usr/share/php'${PHP_MV}':'"${EPREFIX}"'/usr/share/php"|' -i "${phpinisrc}" + + + dodir "${PHP_INI_DIR#${EPREFIX}}" + insinto "${PHP_INI_DIR#${EPREFIX}}" + newins "${phpinisrc}" "${PHP_INI_FILE}" + + elog "Installing php.ini for ${phpsapi} into ${PHP_INI_DIR#${EPREFIX}}" + elog + + dodir "${PHP_EXT_INI_DIR#${EPREFIX}}" + dodir "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}" + + if use_if_iuse opcache; then + elog "Adding opcache to $PHP_EXT_INI_DIR" + echo "zend_extension=${PHP_DESTDIR}/$(get_libdir)/opcache.so" >> "${D}/${PHP_EXT_INI_DIR}"/opcache.ini + dosym "${PHP_EXT_INI_DIR#${EPREFIX}}/opcache.ini" "${PHP_EXT_INI_DIR_ACTIVE#${EPREFIX}}/opcache.ini" + fi + + # SAPI-specific handling + + if [[ "${sapi}" == "fpm" ]] ; then + [[ -z ${PHP_FPM_CONF_VER} ]] && PHP_FPM_CONF_VER=0 + einfo "Installing FPM CGI config file php-fpm.conf" + insinto "${PHP_INI_DIR#${EPREFIX}}" + newins "${FILESDIR}/php-fpm-r${PHP_FPM_CONF_VER}.conf" php-fpm.conf + + # Remove bogus /etc/php-fpm.conf.default (bug 359906) + [[ -f "${ED}/etc/php-fpm.conf.default" ]] && rm "${ED}/etc/php-fpm.conf.default" + fi + + # Install PHP ini files into /usr/share/php + + dodoc php.ini-development + dodoc php.ini-production + +} + +php_set_ini_dir() { + PHP_INI_DIR="${EPREFIX}/etc/php/${1}-php${SLOT}" + PHP_EXT_INI_DIR="${PHP_INI_DIR}/ext" + PHP_EXT_INI_DIR_ACTIVE="${PHP_INI_DIR}/ext-active" +} + +src_prepare() { + # USE=sharedmem (session/mod_mm to be exact) tries to mmap() this path + # ([empty session.save_path]/session_mm_[sapi][gid].sem) + # there is no easy way to circumvent that, all php calls during + # install use -n, so no php.ini file will be used. + # As such, this is the easiest way to get around + addpredict /session_mm_cli250.sem + addpredict /session_mm_cli0.sem + + # Change PHP branding + # Get the alpha/beta/rc version + sed -re "s|^(PHP_EXTRA_VERSION=\").*(\")|\1-pl${PR/r/}-gentoo\2|g" \ + -i configure.in || die "Unable to change PHP branding" + + + epatch "${FILESDIR}"/iodbc-pkgconfig.patch + epatch "${FILESDIR}"/stricter-libc-client-symlink-check.patch + epatch "${FILESDIR}"/all_strict_aliasing.patch + + # Patch PHP to show Gentoo as the server platform + sed -e 's/PHP_UNAME=`uname -a | xargs`/PHP_UNAME=`uname -s -n -r -v | xargs`/g' \ + -i configure.in || die "Failed to fix server platform name" + + # Prevent PHP from activating the Apache config, + # as we will do that ourselves + sed -i \ + -e "s,-i -a -n php${PHP_MV},-i -n php${PHP_MV},g" \ + -e "s,-i -A -n php${PHP_MV},-i -n php${PHP_MV},g" \ + configure sapi/apache2filter/config.m4 sapi/apache2handler/config.m4 + + # Patch PHP to support heimdal instead of mit-krb5 + if has_version "app-crypt/heimdal" ; then + sed -e 's|gssapi_krb5|gssapi|g' -i acinclude.m4 \ + || die "Failed to fix heimdal libname" + sed -e 's|PHP_ADD_LIBRARY(k5crypto, 1, $1)||g' -i acinclude.m4 \ + || die "Failed to fix heimdal crypt library reference" + fi + + #Add user patches #357637 + epatch_user + + #force rebuilding aclocal.m4 + rm aclocal.m4 + eautoreconf + + if [[ ${CHOST} == *-darwin* ]] ; then + # http://bugs.php.net/bug.php?id=48795, bug #343481 + sed -i -e '/BUILD_CGI="\\$(CC)/s/CC/CXX/' configure || die + fi +} + +src_configure() { + addpredict /usr/share/snmp/mibs/.index + addpredict /var/lib/net-snmp/mib_indexes + + PHP_DESTDIR="${EPREFIX}/usr/$(get_libdir)/php${SLOT}" + + # This is a global variable and should be in caps. It isn't because the + # phpconfutils eclass relies on exactly this name... + # for --with-libdir see bug #327025 + my_conf=" + --prefix="${PHP_DESTDIR}" + --mandir="${PHP_DESTDIR}"/man + --infodir="${PHP_DESTDIR}"/info + --libdir="${PHP_DESTDIR}"/lib + --with-libdir=$(get_libdir) + --without-pear + $(use_enable threads maintainer-zts)" + + # extension USE flag shared + my_conf+=" + $(use_enable bcmath bcmath ) + $(use_with bzip2 bz2 "${EPREFIX}"/usr) + $(use_enable calendar calendar ) + $(use_enable ctype ctype ) + $(use_with curl curl "${EPREFIX}"/usr) + $(use_enable xml dom ) + $(use_with enchant enchant "${EPREFIX}"/usr) + $(use_enable exif exif ) + $(use_enable fileinfo fileinfo ) + $(use_enable filter filter ) + $(use_enable ftp ftp ) + $(use_with nls gettext "${EPREFIX}"/usr) + $(use_with gmp gmp "${EPREFIX}"/usr) + $(use_enable hash hash ) + $(use_with mhash mhash "${EPREFIX}"/usr) + $(use_with iconv iconv $(use elibc_glibc || echo "${EPREFIX}"/usr)) + $(use_enable intl intl ) + $(use_enable ipv6 ipv6 ) + $(use_enable json json ) + $(use_with kerberos kerberos "${EPREFIX}"/usr) + $(use_enable xml libxml ) + $(use_with xml libxml-dir "${EPREFIX}"/usr) + $(use_enable unicode mbstring ) + $(use_with crypt mcrypt "${EPREFIX}"/usr) + $(use_with mssql mssql "${EPREFIX}"/usr) + $(use_with unicode onig "${EPREFIX}"/usr) + $(use_with ssl openssl "${EPREFIX}"/usr) + $(use_with ssl openssl-dir "${EPREFIX}"/usr) + $(use_enable pcntl pcntl ) + $(use_enable phar phar ) + $(use_enable pdo pdo ) + $(use_enable opcache opcache ) + $(use_with postgres pgsql "${EPREFIX}"/usr) + $(use_enable posix posix ) + $(use_with spell pspell "${EPREFIX}"/usr) + $(use_with recode recode "${EPREFIX}"/usr) + $(use_enable simplexml simplexml ) + $(use_enable sharedmem shmop ) + $(use_with snmp snmp "${EPREFIX}"/usr) + $(use_enable soap soap ) + $(use_enable sockets sockets ) + $(use_with sqlite sqlite3 "${EPREFIX}"/usr) + $(use_with sybase-ct sybase-ct "${EPREFIX}"/usr) + $(use_enable sysvipc sysvmsg ) + $(use_enable sysvipc sysvsem ) + $(use_enable sysvipc sysvshm ) + $(use_with tidy tidy "${EPREFIX}"/usr) + $(use_enable tokenizer tokenizer ) + $(use_enable wddx wddx ) + $(use_enable xml xml ) + $(use_enable xmlreader xmlreader ) + $(use_enable xmlwriter xmlwriter ) + $(use_with xmlrpc xmlrpc) + $(use_with xsl xsl "${EPREFIX}"/usr) + $(use_enable zip zip ) + $(use_with zlib zlib "${EPREFIX}"/usr) + $(use_enable debug debug )" + + # DBA support + if use cdb || use berkdb || use flatfile || use gdbm || use inifile \ + || use qdbm ; then + my_conf="${my_conf} --enable-dba${shared}" + fi + + # DBA drivers support + my_conf+=" + $(use_with cdb cdb) + $(use_with berkdb db4 ${EPREFIX}/usr) + $(use_enable flatfile flatfile ) + $(use_with gdbm gdbm ${EPREFIX}/usr) + $(use_enable inifile inifile ) + $(use_with qdbm qdbm ${EPREFIX}/usr)" + + # Support for the GD graphics library + my_conf+=" + $(use_with truetype freetype-dir ${EPREFIX}/usr) + $(use_with truetype t1lib ${EPREFIX}/usr) + $(use_enable cjk gd-jis-conv ) + $(use_with gd jpeg-dir ${EPREFIX}/usr) + $(use_with gd png-dir ${EPREFIX}/usr) + $(use_with xpm xpm-dir ${EPREFIX}/usr)" + # enable gd last, so configure can pick up the previous settings + my_conf+=" + $(use_with gd gd)" + + # IMAP support + if use imap ; then + my_conf+=" + $(use_with imap imap ${EPREFIX}/usr) + $(use_with ssl imap-ssl ${EPREFIX}/usr)" + fi + + # Interbase/firebird support + + if use firebird ; then + my_conf+=" + $(use_with firebird interbase ${EPREFIX}/usr)" + fi + + # LDAP support + if use ldap ; then + my_conf+=" + $(use_with ldap ldap ${EPREFIX}/usr) + $(use_with ldap-sasl ldap-sasl ${EPREFIX}/usr)" + fi + + # MySQL support + local mysqllib="mysqlnd" + local mysqlilib="mysqlnd" + use libmysqlclient && mysqllib="${EPREFIX}/usr" + use libmysqlclient && mysqlilib="${EPREFIX}/usr/bin/mysql_config" + + my_conf+=" $(use_with mysql mysql $mysqllib)" + my_conf+=" $(use_with mysqli mysqli $mysqlilib)" + + local mysqlsock=" $(use_with mysql mysql-sock ${EPREFIX}/var/run/mysqld/mysqld.sock)" + if use mysql ; then + my_conf+="${mysqlsock}" + elif use mysqli ; then + my_conf+="${mysqlsock}" + fi + + # ODBC support + if use odbc ; then + my_conf+=" + $(use_with odbc unixODBC ${EPREFIX}/usr)" + fi + + if use iodbc ; then + my_conf+=" + $(use_with iodbc iodbc ${EPREFIX}/usr)" + fi + + # Oracle support + if use oci8-instant-client ; then + my_conf+=" + $(use_with oci8-instant-client oci8)" + fi + + # PDO support + if use pdo ; then + my_conf+=" + $(use_with mssql pdo-dblib ) + $(use_with mysql pdo-mysql ${mysqllib}) + $(use_with postgres pdo-pgsql ) + $(use_with sqlite pdo-sqlite ${EPREFIX}/usr) + $(use_with odbc pdo-odbc unixODBC,${EPREFIX}/usr)" + if use oci8-instant-client ; then + my_conf+=" + $(use_with oci8-instant-client pdo-oci)" + fi + fi + + # readline/libedit support + my_conf+=" + $(use_with readline readline ${EPREFIX}/usr) + $(use_with libedit libedit ${EPREFIX}/usr)" + + # Session support + if use session ; then + my_conf+=" + $(use_with sharedmem mm ${EPREFIX}/usr)" + else + my_conf+=" + $(use_enable session session )" + fi + + # Use pic for shared modules such as apache2's mod_php + my_conf="${my_conf} --with-pic" + + # we use the system copy of pcre + # --with-pcre-regex affects ext/pcre + # --with-pcre-dir affects ext/filter and ext/zip + my_conf="${my_conf} --with-pcre-regex=${EPREFIX}/usr --with-pcre-dir=${EPREFIX}/usr" + + # Catch CFLAGS problems + # Fixes bug #14067. + # Changed order to run it in reverse for bug #32022 and #12021. + replace-cpu-flags "k6*" "i586" + + # Support user-passed configuration parameters + my_conf="${my_conf} ${EXTRA_ECONF:-}" + + # Support the Apache2 extras, they must be set globally for all + # SAPIs to work correctly, especially for external PHP extensions + + mkdir -p "${WORKDIR}/sapis-build" + for one_sapi in $SAPIS ; do + use "${one_sapi}" || continue + php_set_ini_dir "${one_sapi}" + + cp -r "${S}" "${WORKDIR}/sapis-build/${one_sapi}" + cd "${WORKDIR}/sapis-build/${one_sapi}" + + sapi_conf="${my_conf} --with-config-file-path=${PHP_INI_DIR} + --with-config-file-scan-dir=${PHP_EXT_INI_DIR_ACTIVE}" + + for sapi in $SAPIS ; do + case "$sapi" in + cli|cgi|embed|fpm) + if [[ "${one_sapi}" == "${sapi}" ]] ; then + sapi_conf="${sapi_conf} --enable-${sapi}" + else + sapi_conf="${sapi_conf} --disable-${sapi}" + fi + ;; + + apache2) + if [[ "${one_sapi}" == "${sapi}" ]] ; then + sapi_conf="${sapi_conf} --with-apxs2=${EPREFIX}/usr/sbin/apxs" + else + sapi_conf="${sapi_conf} --without-apxs2" + fi + ;; + esac + done + + econf ${sapi_conf} + done +} + +src_compile() { + # snmp seems to run during src_compile, too (bug #324739) + addpredict /usr/share/snmp/mibs/.index + addpredict /var/lib/net-snmp/mib_indexes + + for sapi in ${SAPIS} ; do + if use "${sapi}"; then + cd "${WORKDIR}/sapis-build/$sapi" || "Failed to change dir to ${WORKDIR}/sapis-build/$1" + emake || die "emake failed" + fi + done +} + +src_install() { + # see bug #324739 for what happens when we don't have that + addpredict /usr/share/snmp/mibs/.index + + # grab the first SAPI that got built and install common files from there + local first_sapi="" + for sapi in $SAPIS ; do + if use $sapi ; then + first_sapi=$sapi + break + fi + done + + # Makefile forgets to create this before trying to write to it... + dodir "${PHP_DESTDIR#${EPREFIX}}/bin" + + # Install php environment (without any sapis) + cd "${WORKDIR}/sapis-build/$first_sapi" + emake INSTALL_ROOT="${D}" \ + install-build install-headers install-programs \ + || die "emake install failed" + + local extension_dir="$("${ED}/${PHP_DESTDIR#${EPREFIX}}/bin/php-config" --extension-dir)" + + # Create the directory where we'll put version-specific php scripts + keepdir /usr/share/php${PHP_MV} + + local sapi="", file="" + local sapi_list="" + + for sapi in ${SAPIS}; do + if use "${sapi}" ; then + einfo "Installing SAPI: ${sapi}" + cd "${WORKDIR}/sapis-build/${sapi}" + + if [[ "${sapi}" == "apache2" ]] ; then + # We're specifically not using emake install-sapi as libtool + # may cause unnecessary relink failures (see bug #351266) + insinto "${PHP_DESTDIR#${EPREFIX}}/apache2/" + newins ".libs/libphp5$(get_libname)" "libphp${PHP_MV}$(get_libname)" + keepdir "/usr/$(get_libdir)/apache2/modules" + else + # needed each time, php_install_ini would reset it + into "${PHP_DESTDIR#${EPREFIX}}" + case "$sapi" in + cli) + source="sapi/cli/php" + ;; + cgi) + source="sapi/cgi/php-cgi" + ;; + fpm) + source="sapi/fpm/php-fpm" + ;; + embed) + source="libs/libphp${PHP_MV}$(get_libname)" + ;; + *) + die "unhandled sapi in src_install" + ;; + esac + + if [[ "${source}" == *"$(get_libname)" ]]; then + dolib.so "${source}" || die "Unable to install ${sapi} sapi" + else + dobin "${source}" || die "Unable to install ${sapi} sapi" + fi + fi + + php_install_ini "${sapi}" + + # construct correct SAPI string for php-config + # thanks to ferringb for the bash voodoo + if [[ "${sapi}" == "apache2" ]]; then + sapi_list="${sapi_list:+${sapi_list} }apache2handler" + else + sapi_list="${sapi_list:+${sapi_list} }${sapi}" + fi + fi + done + + # Installing opcache module + if use_if_iuse opcache ; then + dolib.so "modules/opcache$(get_libname)" || die "Unable to install opcache module" + fi + + # Install env.d files + newenvd "${FILESDIR}/20php5-envd" \ + "20php${SLOT}" + sed -e "s|/lib/|/$(get_libdir)/|g" -i \ + "${ED}/etc/env.d/20php${SLOT}" + sed -e "s|php5|php${SLOT}|g" -i \ + "${ED}/etc/env.d/20php${SLOT}" + + # set php-config variable correctly (bug #278439) + sed -e "s:^\(php_sapis=\)\".*\"$:\1\"${sapi_list}\":" -i \ + "${ED}/usr/$(get_libdir)/php${SLOT}/bin/php-config" +} + +src_test() { + echo ">>> Test phase [test]: ${CATEGORY}/${PF}" + PHP_BIN="${WORKDIR}/sapis-build/cli/sapi/cli/php" + if [[ ! -x "${PHP_BIN}" ]] ; then + ewarn "Test phase requires USE=cli, skipping" + return + else + export TEST_PHP_EXECUTABLE="${PHP_BIN}" + fi + + if [[ -x "${WORKDIR}/sapis/cgi/php-cgi" ]] ; then + export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis/cgi/php-cgi" + fi + + REPORT_EXIT_STATUS=1 "${TEST_PHP_EXECUTABLE}" -n -d "session.save_path=${T}" \ + "${WORKDIR}/sapis-build/cli/run-tests.php" -n -q -d "session.save_path=${T}" + + for name in ${EXPECTED_TEST_FAILURES}; do + mv "${name}.out" "${name}.out.orig" 2>/dev/null + done + + local failed="$(find -name '*.out')" + if [[ ${failed} != "" ]] ; then + ewarn "The following test cases failed unexpectedly:" + for name in ${failed}; do + ewarn " ${name/.out/}" + done + else + einfo "No unexpected test failures, all fine" + fi + + if [[ ${PHP_SHOW_UNEXPECTED_TEST_PASS} == "1" ]] ; then + local passed="" + for name in ${EXPECTED_TEST_FAILURES}; do + [[ -f "${name}.diff" ]] && continue + passed="${passed} ${name}" + done + if [[ ${passed} != "" ]] ; then + einfo "The following test cases passed unexpectedly:" + for name in ${passed}; do + ewarn " ${passed}" + done + else + einfo "None of the known-to-fail tests passed, all fine" + fi + fi +} + +pkg_postinst() { + # Output some general info to the user + if use apache2 ; then + APACHE2_MOD_DEFINE="PHP5" + APACHE2_MOD_CONF="70_mod_php5" + apache-module_pkg_postinst + fi + + # Create the symlinks for php + for m in ${SAPIS}; do + [[ ${m} == 'embed' ]] && continue; + if use $m ; then + local ci=$(eselect php show $m) + if [[ -z $ci ]]; then + eselect php set $m php${SLOT} + einfo "Switched ${m} to use php:${SLOT}" + einfo + elif [[ $ci != "php${SLOT}" ]] ; then + elog "To switch $m to use php:${SLOT}, run" + elog " eselect php set $m php${SLOT}" + elog + fi + fi + done + + elog "Make sure that PHP_TARGETS in ${EPREFIX}/etc/make.conf includes php${SLOT/./-} in order" + elog "to compile extensions for the ${SLOT} ABI" + elog + if ! use readline && use cli ; then + ewarn "Note that in order to use php interactivly, you need to enable" + ewarn "the readline USE flag or php -a will hang" + fi + elog + elog "This ebuild installed a version of php.ini based on php.ini-${PHP_INI_VERSION} version." + elog "You can chose which version of php.ini to install by default by setting PHP_INI_VERSION to either" + elog "'production' or 'development' in ${EPREFIX}/etc/make.conf" + elog "Both versions of php.ini can be found in ${EPREFIX}/usr/share/doc/${PF}" + + elog + elog "For more details on how minor version slotting works (PHP_TARGETS) please read the upgrade guide:" + elog "http://www.gentoo.org/proj/en/php/php-upgrading.xml" + elog +} + +pkg_prerm() { + eselect php cleanup +} |