]> git.pld-linux.org Git - packages/php.git/blobdiff - php.spec
move duplicate opcache php.ini settings to specific opcache.ini
[packages/php.git] / php.spec
index acab650390d297125f831133dbe07f8c7d0274a4..5ed55826d800e197a15086c999e3b017624f3432 100644 (file)
--- a/php.spec
+++ b/php.spec
@@ -1,11 +1,13 @@
+# NOTES
+# - mysqlnd driver doesn't support reconnect: https://bugs.php.net/bug.php?id=52561
+# TODO 7.2:
+# - https://github.com/php/php-src/blob/php-7.2.0/UPGRADING
 # TODO 5.6:
 # - enable --with-fpm-systemd, but ensure it checks for sd_booted()
-# - build with system libgd 2.1, see 73c5128
 # TODO 5.4:
 # - update imap annotations patch (needs api porting)
 # - update imap myrights patch (needs api porting)
 # --with-libmbfl=DIR      MBSTRING: Use external libmbfl.  DIR is the libmbfl base install directory BUNDLED
-# --with-onig=DIR         MBSTRING: Use external oniguruma. DIR is the oniguruma install prefix.
 # TODO:
 # - fileinfo extension bundles magic db in library: data_file.c (dump of magic.mgc) is 14M
 #   - 2.3M fileinfo.so php54-fileinfo-5.4.6-0.15.x86_64
@@ -31,7 +33,6 @@
 %bcond_without embed           # disable building Embedded API
 %bcond_with    gcov            # Enable Code coverage reporting
 %bcond_without kerberos5       # without Kerberos5 support
-%bcond_with    suhosin         # with suhosin patch, has little point in PHP>=5.3, see https://github.com/stefanesser/suhosin/issues/42#issuecomment-41728178
 %bcond_with    systemtap       # systemtap/DTrace support
 %bcond_with    tests           # default off; test process very often hangs on builders, approx run time 45m; perform "make test"
 %bcond_with    zts             # Zend Thread Safety
@@ -66,7 +67,6 @@
 %bcond_without json            # without json extension module
 %bcond_without ldap            # without LDAP extension module
 %bcond_without mbstring        # without mbstring extension module
-%bcond_without mcrypt          # without mbcrypt extension module
 %bcond_without mhash           # without mhash extension (supported by hash extension)
 %bcond_without mysqli          # without mysqli support (Requires mysql >= 4.1)
 %bcond_without mysqlnd         # without mysqlnd support in mysql related extensions
 %bcond_without recode          # without recode extension module
 %bcond_without session         # without session extension module
 %bcond_without snmp            # without SNMP extension module
+%bcond_without sodium          # without sodium extension module
 %bcond_without sqlite2         # without SQLite extension module
 %bcond_without sqlite3         # without SQLite3 extension module
 %bcond_without tidy            # without Tidy extension module
 %bcond_without wddx            # without WDDX extension module
 %bcond_without xmlrpc          # without XML-RPC extension module
+%bcond_without xsl             # without xsl extension module
 # extensions options
+%bcond_without argon2          # argon2 password hashing
 %bcond_without instantclient   # build Oracle oci8 extension module against oracle-instantclient package
 %bcond_with    interbase_inst  # use InterBase install., not Firebird  (BR: proprietary libs)
 %bcond_with    mm              # without mm support for session storage
-%bcond_with    system_gd       # with system gd (imageantialias function is missing then)
-%bcond_with    system_libzip   # with system libzip (reported broken currently)
+%bcond_without system_gd       # system gd
+%bcond_without system_libzip   # system libzip
 %bcond_without webp            # Without WebP support in GD extension (imagecreatefromwebp)
 
 %define apxs1          /usr/sbin/apxs1
 %endif
 
 %define                orgname php
-%define                ver_suffix 70
+%define                ver_suffix 72
 %define                php_suffix %{!?with_default_php:%{ver_suffix}}
 Summary:       PHP: Hypertext Preprocessor
 Summary(fr.UTF-8):     Le langage de script embarque-HTML PHP
@@ -150,16 +153,17 @@ Summary(pt_BR.UTF-8):     A linguagem de script PHP
 Summary(ru.UTF-8):     PHP Версии 7 - язык препроцессирования HTML-файлов, выполняемый на сервере
 Summary(uk.UTF-8):     PHP Версії 7 - мова препроцесування HTML-файлів, виконувана на сервері
 Name:          %{orgname}%{php_suffix}
-Version:       7.0.13
-Release:       1
+Version:       7.2.0
+Release:       5
 Epoch:         4
 # All files licensed under PHP version 3.01, except
 # Zend is licensed under Zend
 # TSRM is licensed under BSD
 License:       PHP 3.01 and Zend and BSD
 Group:         Libraries
-Source0:       http://php.net/distributions/%{orgname}-%{version}.tar.xz
-# Source0-md5: eb117bf1d1efc99c522f132b265a3402
+Source0:       https://php.net/distributions/%{orgname}-%{version}.tar.xz
+# Source0-md5: ef8d4764f16d5f066e9893fe91887a31
+Source1:       opcache.ini
 Source2:       %{orgname}-mod_php.conf
 Source3:       %{orgname}-cgi-fcgi.ini
 Source4:       %{orgname}-apache.ini
@@ -194,9 +198,6 @@ Patch27:    %{orgname}-config-dir.patch
 Patch29:       %{orgname}-fcgi-graceful.patch
 Patch31:       %{orgname}-fcgi-error_log-no-newlines.patch
 Patch34:       %{orgname}-libtool.patch
-#Patch36:      %{orgname}-mysql-charsetphpini.patch
-#Patch37:      %{orgname}-mysqli-charsetphpini.patch
-#Patch38:      %{orgname}-pdo_mysql-charsetphpini.patch
 Patch39:       %{orgname}-use-prog_sendmail.patch
 Patch41:       %{orgname}-fpm-config.patch
 Patch42:       %{orgname}-fpm-shared.patch
@@ -204,7 +205,6 @@ Patch43:    %{orgname}-silent-session-cleanup.patch
 Patch44:       %{orgname}-include_path.patch
 Patch45:       %{orgname}-imap-annotations.patch
 Patch46:       %{orgname}-imap-myrights.patch
-Patch47:       suhosin.patch
 Patch50:       extension-shared-optional-dep.patch
 Patch51:       spl-shared.patch
 Patch52:       pcre-shared.patch
@@ -212,13 +212,10 @@ Patch53:  fix-test-run.patch
 Patch55:       bug-52078-fileinode.patch
 Patch59:       %{orgname}-systzdata.patch
 Patch60:       %{orgname}-oracle-instantclient.patch
-Patch62:       mcrypt-libs.patch
-Patch65:       system-libzip.patch
 Patch66:       php-db.patch
 Patch67:       mysql-lib-ver-mismatch.patch
 # https://bugs.php.net/bug.php?id=68344
 Patch68:       php-mysql-ssl-context.patch
-Patch69:       fpm-conf-split.patch
 Patch70:       mysqlnd-ssl.patch
 Patch71:       libdb-info.patch
 Patch72:       phar-hash-shared.patch
@@ -235,11 +232,8 @@ BuildRequires:     db-devel >= 4.0
 BuildRequires: elfutils-devel
 %{?with_enchant:BuildRequires: enchant-devel >= 1.1.3}
 %{?with_kerberos5:BuildRequires:       heimdal-devel}
-%{?with_fpm:BuildRequires:     libapparmor-devel}
-%{?with_system_libzip:BuildRequires:   libzip-devel >= 0.10.1-2}
-%{!?with_mysqlnd:BuildRequires:        mysql-devel}
-BuildRequires: pkgconfig
-BuildRequires: sed >= 4.0
+%{?with_argon2:BuildRequires:  libargon2-devel >= 20161029}
+%{?with_sodium:BuildRequires:  libsodium-devel >= 1.0.8}
 %if %{with pdo_dblib}
 BuildRequires: freetds-devel >= 0.82
 %endif
@@ -250,29 +244,32 @@ BuildRequires:    gd-devel >= 2.1
 BuildRequires: gdbm-devel
 BuildRequires: gmp-devel >= 4.2
 %{?with_imap:BuildRequires:    imap-devel >= 1:2007e-2}
+%{?with_gcov:BuildRequires:    lcov}
+%{?with_fpm:BuildRequires:     libapparmor-devel}
 %{?with_intl:BuildRequires:    libicu-devel >= 4.4}
 BuildRequires: libjpeg-devel
 BuildRequires: libltdl-devel >= 1.4
-BuildRequires: libmcrypt-devel >= 2.5.6
 BuildRequires: libpng-devel >= 1.0.8
 %{?with_intl:BuildRequires:    libstdc++-devel}
 %{?with_webp:BuildRequires:    libwebp-devel}
-BuildRequires: tokyocabinet-devel
 %if "%{pld_release}" != "ac"
 BuildRequires: libtool >= 2:2.4.6
 %else
 BuildRequires: libtool >= 1.4.3
 %endif
 BuildRequires: libxml2-devel >= 1:2.7.6-4
-BuildRequires: libxslt-devel >= 1.1.0
+%{?with_xsl:BuildRequires:     libxslt-devel >= 1.1.0}
+%{?with_system_libzip:BuildRequires:   libzip-devel >= 1.2.0}
+%{?with_snmp:%{?with_tests:BuildRequires:      mibs-net-snmp}}
 %{?with_mm:BuildRequires:      mm-devel >= 1.3.0}
+%{!?with_mysqli:BuildRequires: mysql-devel >= 4.1.13}
+%{!?with_pdo_mysql:BuildRequires:      mysql-devel}
+%{?with_snmp:BuildRequires:    net-snmp-devel >= 5.3}
+BuildRequires: oniguruma-devel
 %{?with_ldap:BuildRequires:    openldap-devel >= 2.3.0}
 %if %{with openssl} || %{with ldap}
-BuildRequires: openssl-devel >= 0.9.8
+BuildRequires: openssl-devel >= 1.0.1
 %endif
-%{?with_gcov:BuildRequires:    lcov}
-%{?with_snmp:%{?with_tests:BuildRequires:      mibs-net-snmp}}
-%{?with_snmp:BuildRequires:    net-snmp-devel >= 5.0.7}
 %{?with_oci:%{?with_instantclient:BuildRequires:       oracle-instantclient-devel}}
 BuildRequires: pam-devel
 %{?with_pcre:BuildRequires:    pcre-devel >= 8.10}
@@ -283,16 +280,18 @@ BuildRequires:    readline-devel
 BuildRequires: rpm >= 4.4.9-56
 BuildRequires: rpm-build >= 4.4.0
 BuildRequires: rpmbuild(macros) >= 1.566
-%{?with_systemtap:BuildRequires:       systemtap-sdt-devel}
-BuildRequires: tar >= 1:1.22
-BuildRequires: xz
+BuildRequires: sed >= 4.0
 %if %{with sqlite3} || %{with pdo_sqlite}
 BuildRequires: sqlite3-devel >= 3.3.9
 %endif
+%{?with_systemtap:BuildRequires:       systemtap-sdt-devel}
+BuildRequires: tar >= 1:1.22
 %{?with_tidy:BuildRequires:    tidy-devel}
+BuildRequires: tokyocabinet-devel
 %{?with_odbc:BuildRequires:    unixODBC-devel}
 %{?with_xmlrpc:BuildRequires:  xmlrpc-epi-devel >= 0.54.1}
-BuildRequires: zlib-devel >= 1.0.9
+BuildRequires: xz
+BuildRequires: zlib-devel >= 1.2.0.4
 %if %{with apache2}
 BuildRequires: apache-devel >= 2.0.52-2
 BuildRequires: apr-devel >= 1:1.0.0
@@ -305,22 +304,23 @@ BuildRoot:        %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 %define                _sysconfdir                     %{php_sysconfdir}
 
 # must be in sync with source. extra check ensuring that it is so is done in %%build
-%define                php_api_version         20151012
-%define                zend_module_api         20151012
-%define                zend_extension_api      320151012
-%define                php_pdo_api_version     20150127
+%define                php_api_version         20170718
+%define                zend_module_api         20170718
+%define                zend_extension_api      320170718
+%define                php_pdo_api_version     20170320
 
 # Extension versions
 %define                bz2ver          1.0
-%define                enchantver      1.1.0
+%define                enchantver      %{version}
 %define                fileinfover     1.0.5
 %define                hashver         1.0
 %define                intlver         1.1.0
-%define                jsonver         1.4.0
+%define                jsonver         1.6.0
 %define                pharver         2.0.2
-%define                sqlite3ver      0.7-dev
-%define                zipver          1.13.5
+%define                sqlite3ver      %{version}
+%define                zipver          1.15.1
 %define                phpdbgver       0.5.0
+%define                sodiumver       %{version}
 
 %define                _zend_zts               %{!?with_zts:0}%{?with_zts:1}
 %define                php_debug               %{!?debug:0}%{?debug:1}
@@ -388,20 +388,33 @@ PHP - це мова написання скриптів, що вбудовуют
 використання PHP - заміна для CGI скриптів.
 
 %package -n apache-mod_%{name}
-Summary:       PHP DSO module for Apache 2.x
-Summary(pl.UTF-8):     Moduł DSO (Dynamic Shared Object) PHP dla Apache 2.x
+Summary:       PHP support for Apache 2.x
+Summary(pl.UTF-8):     Wsparcie PHP dla Apache 2.x
 Group:         Development/Languages/PHP
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
-Requires:      apache(modules-api) = %{apache_modules_api}
-Requires:      apache-mod_mime
+Requires:      apache-mod_%{name}-core = %{epoch}:%{version}-%{release}
 Provides:      webserver(php) = %{version}
 Obsoletes:     apache-mod_php < 4:5.3.28-7
 Obsoletes:     phpfi
 
 %description -n apache-mod_%{name}
-PHP as DSO module for Apache 2.x.
+PHP support for Apache 2.x.
 
 %description -n apache-mod_%{name} -l pl.UTF-8
+Wsparcie PHP dla Apache 2.x.
+
+%package -n apache-mod_%{name}-core
+Summary:       PHP DSO module for Apache 2.x
+Summary(pl.UTF-8):     Moduł DSO (Dynamic Shared Object) PHP dla Apache 2.x
+Group:         Development/Languages/PHP
+Requires:      %{name}-common = %{epoch}:%{version}-%{release}
+Requires:      apache(modules-api) = %{apache_modules_api}
+Requires:      apache-mod_mime
+
+%description -n apache-mod_%{name}-core
+PHP as DSO module for Apache 2.x.
+
+%description -n apache-mod_%{name}-core -l pl.UTF-8
 PHP jako moduł DSO (Dynamic Shared Object) dla Apache 2.x.
 
 %package litespeed
@@ -545,6 +558,7 @@ Requires:   glibc >= 6:2.3.5
 Requires:      php-dirs >= 1.4
 Requires:      rpm-whiteout >= 1.28
 Requires:      tzdata
+Requires:      zlib >= 1.2.0.4
 Provides:      %{name}(debug) = %{php_debug}
 Provides:      %{name}(modules_api) = %{php_api_version}
 Provides:      %{name}(thread-safety) = %{_zend_zts}
@@ -615,6 +629,8 @@ Obsoletes:  php53-devel
 Obsoletes:     php54-devel
 Obsoletes:     php55-devel
 Obsoletes:     php56-devel
+Obsoletes:     php70-devel
+Obsoletes:     php71-devel
 
 %description devel
 The php-devel package lets you compile dynamic extensions to PHP.
@@ -1103,23 +1119,6 @@ string support.
 %description mbstring -l pl.UTF-8
 Moduł PHP dodający obsługę ciągów znaków wielobajtowych.
 
-%package mcrypt
-Summary:       mcrypt extension module for PHP
-Summary(pl.UTF-8):     Moduł mcrypt dla PHP
-Group:         Libraries
-URL:           http://php.net/manual/en/book.mcrypt.php
-Requires:      %{name}-common = %{epoch}:%{version}-%{release}
-Requires:      libmcrypt >= 2.5.6
-Provides:      php(mcrypt)
-Obsoletes:     php-mcrypt < 4:5.3.28-7
-
-%description mcrypt
-This is a dynamic shared object (DSO) for PHP that will add mcrypt
-support.
-
-%description mcrypt -l pl.UTF-8
-Moduł PHP dodający możliwość szyfrowania poprzez bibliotekę mcrypt.
-
 %package mysqli
 Summary:       MySQLi module for PHP
 Summary(pl.UTF-8):     Moduł MySQLi dla PHP
@@ -1128,6 +1127,7 @@ URL:              http://php.net/manual/en/book.mysqli.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 %{?with_mysqlnd:Requires:      %{name}-mysqlnd = %{epoch}:%{version}-%{release}}
 Requires:      %{name}-spl = %{epoch}:%{version}-%{release}
+Requires:      mysql-libs >= 4.1.13
 Provides:      php(mysqli)
 Obsoletes:     php-mysqli < 4:5.3.28-7
 
@@ -1320,7 +1320,7 @@ Group:            Libraries
 URL:           http://php.net/manual/en/ref.pdo-dblib.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
-Provides:      php(dblib)
+Provides:      php(pdo_dblib)
 Obsoletes:     php-pdo-dblib < 4:5.3.28-7
 
 %description pdo-dblib
@@ -1339,6 +1339,7 @@ URL:              http://php.net/manual/en/ref.pdo-firebird.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-firebird)
+Provides:      php(pdo_firebird)
 Obsoletes:     php-pdo-firebird < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_FIREBIRD
 
@@ -1359,6 +1360,7 @@ Requires: %{name}-common = %{epoch}:%{version}-%{release}
 %{?with_mysqlnd:Requires:      %{name}-mysqlnd = %{epoch}:%{version}-%{release}}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-mysql)
+Provides:      php(pdo_mysql)
 Obsoletes:     php-pdo-mysql < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_MYSQL
 
@@ -1378,6 +1380,7 @@ URL:              http://php.net/manual/en/ref.pdo-oci.php
 %{?requires_php_extension}
 %{?requires_php_pdo_module}
 Provides:      php(pdo-oci)
+Provides:      php(pdo_oci)
 Obsoletes:     php-pdo-oci < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_OCI
 
@@ -1397,6 +1400,7 @@ URL:              http://php.net/manual/en/ref.pdo-odbc.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-odbc)
+Provides:      php(pdo_odbc)
 Obsoletes:     php-pdo-odbc < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_ODBC
 
@@ -1416,7 +1420,7 @@ URL:              http://php.net/manual/en/ref.pdo-pgsql.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-pgsql)
-Provides:      php-pecl-PDO_PGSQL
+Provides:      php(pdo_pgsql)
 Obsoletes:     php-pdo-pgsql < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_PGSQL < 4:5.2.1-2
 
@@ -1436,6 +1440,7 @@ URL:              http://php.net/manual/en/ref.pdo-sqlite.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-sqlite)
+Provides:      php(pdo_sqlite)
 Obsoletes:     php-pdo-sqlite < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_SQLITE
 
@@ -1659,6 +1664,16 @@ support.
 %description sockets -l pl.UTF-8
 Moduł PHP dodający obsługę gniazdek.
 
+%package sodium
+Summary:       Wrapper for the Sodium cryptographic library
+Group:         Libraries
+URL:           https://paragonie.com/book/pecl-libsodium
+Requires:      %{name}-common = %{epoch}:%{version}-%{release}
+Provides:      php(sodium) = %{sodiumver}
+
+%description sodium
+A simple, low-level PHP extension for libsodium.
+
 %package spl
 Summary:       Standard PHP Library module for PHP
 Summary(pl.UTF-8):     Moduł biblioteki standardowej (Standard PHP Library) dla PHP
@@ -1760,6 +1775,9 @@ Summary(pl.UTF-8):        Zawiera pliki testów jednostkowych dla PHP i rozszerzeń
 Group:         Libraries
 URL:           http://qa.php.net/
 Requires:      %{name}-cli
+%if "%{_rpmversion}" >= "5"
+BuildArch:     noarch
+%endif
 
 %description tests
 This package contains unit tests for PHP and its extensions.
@@ -1905,7 +1923,7 @@ Group:            Libraries
 URL:           http://php.net/manual/en/book.xsl.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-dom = %{epoch}:%{version}-%{release}
-Requires:      libxslt >= 1.0.18
+Requires:      libxslt >= 1.1.0
 Provides:      php(xsl)
 Obsoletes:     php-xsl < 4:5.3.28-7
 # actually not true, functionality is similar, but API differs
@@ -1924,7 +1942,7 @@ Summary(pl.UTF-8):        Zarządzanie archiwami zip
 Group:         Libraries
 URL:           http://php.net/manual/en/book.zip.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
-%{?with_system_libzip:Requires:        libzip >= 0.10.1-2}
+%{?with_system_libzip:Requires:        libzip >= 1.2.0}
 Provides:      php(zip) = %{zipver}
 Obsoletes:     php-pecl-zip < %{zipver}
 Obsoletes:     php-zip < 4:5.3.28-7
@@ -1953,7 +1971,7 @@ compression support to PHP.
 Moduł PHP umożliwiający używanie kompresji zlib.
 
 %prep
-%setup -q -n %{orgname}-%{version}
+%setup -q -n %{orgname}-%{version}%{?subver}
 cp -p php.ini-production php.ini
 %patch0 -p1
 %patch1 -p1
@@ -1981,51 +1999,29 @@ cp -p php.ini-production php.ini
 %if "%{pld_release}" != "ac"
 %patch34 -p1
 %endif
-#%patch36 -p1
-#%patch37 -p1
-#%patch38 -p1
 %patch39 -p1
-%if %{with fpm}
-%if 0
-# create split php-fpm.conf patch. review (restore other diffs) and commit
-cp sapi/fpm/php-fpm.conf.in{,.orig}
-%{__sed} -n -e '/; Start a new pool named/,$p' sapi/fpm/php-fpm.conf.in > sapi/fpm/php-fpm.conf-d.in
-%{__sed} -i -e '/; Include one or more files/,/include=etc\/fpm\.d/d' sapi/fpm/php-fpm.conf.in
-%{__sed} -i -e '/; Start a new pool named/,$d' sapi/fpm/php-fpm.conf.in
-set +e
-cd ..
-diff -u %{orgname}-%{version}/sapi/fpm/php-fpm.conf.in{.orig,} > %{PATCH69}
-diff -u /dev/null %{orgname}-%{version}/sapi/fpm/php-fpm.conf-d.in >> %{PATCH69}
-exit 1
-%else
-#%patch69 -p1
-%endif
 %patch41 -p1
 %patch42 -p1
-%endif
 %patch43 -p1
 %patch44 -p1
 #%patch45 -p1 # imap annotations. fixme
 #%patch46 -p1 # imap myrights. fixme
-%if %{with suhosin}
-%patch47 -p1
-%endif
 %patch50 -p1
-%patch51 -p1
-%patch52 -p1
+%patch51 -p1 -b .spl-shared
+%patch52 -p1 -b .pcre-shared
 %patch53 -p1
 %undos ext/spl/tests/SplFileInfo_getInode_basic.phpt
 %patch55 -p1
-%patch59 -p1
-%patch60 -p1
-%patch62 -p1
-%{?with_system_libzip:%patch65 -p1}
+%patch59 -p1 -b .systzdata
+%if %{with instantclient}
+%patch60 -p1 -b .instantclient
+%endif
 %patch66 -p1
 %patch67 -p1
 #%patch68 -p1 DROP or update to 7.0 APIs
 %patch70 -p1
 %patch71 -p1
-%patch72 -p1
+%patch72 -p1 -b .phar-shared
 
 %{__sed} -i -e '/PHP_ADD_LIBRARY_WITH_PATH/s#xmlrpc,#xmlrpc-epi,#' ext/xmlrpc/config.m4
 
@@ -2048,7 +2044,7 @@ find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
 #%{__rm} -r ext/dba/libinifile
 #%{__rm} -r ext/gd/libgd
 #%{__rm} -r ext/mbstring/libmbfl
-#%{__rm} -r ext/mbstring/oniguruma
+%{__rm} -r ext/mbstring/oniguruma
 %{__rm} -r ext/pcre/pcrelib
 #%{__rm} -r ext/soap/interop
 %{__rm} -r ext/xmlrpc/libxmlrpc
@@ -2166,12 +2162,16 @@ if test "$ver" != "%{pharver}"; then
        : Update the pharver macro and rebuild.
        exit 1
 fi
-ver=$(sed -n '/#define PHP_SQLITE3_VERSION/{s/.* "//;s/".*$//;p}' ext/sqlite3/php_sqlite3.h)
-if test "$ver" != "%{sqlite3ver}"; then
+ver=$(awk '/#define PHP_SQLITE3_VERSION/ {print $3}' ext/sqlite3/php_sqlite3.h | xargs)
+if test "$ver" != "PHP_VERSION"; then
        : Error: Upstream Sqlite3 version is now ${ver}, expecting %{sqlite3ver}.
        : Update the sqlite3ver macro and rebuild.
        exit 1
 fi
+ver=$(awk '/#define PHP_SODIUM_VERSION/ {print $3}' ext/sodium/php_libsodium.h | xargs)
+if test "$ver" != "PHP_VERSION"; then
+       exit 1
+fi
 ver=$(sed -n '/#define PHP_ZIP_VERSION /{s/.* "//;s/".*$//;p}' ext/zip/php_zip.h)
 if test "$ver" != "%{zipver}"; then
        : Error: Upstream ZIP version is now ${ver}, expecting %{zipver}.
@@ -2196,10 +2196,8 @@ if test "$ver" != "%{bz2ver}"; then
        : Update the bz2ver macro and rebuild.
        exit 1
 fi
-ver=$(sed -n '/#define PHP_ENCHANT_VERSION /{s/.* "//;s/".*$//;p}' ext/enchant/php_enchant.h)
-if test "$ver" != "%{enchantver}"; then
-       : Error: Upstream Enchant version is now ${ver}, expecting %{enchantver}.
-       : Update the enchantver macro and rebuild.
+ver=$(awk '/#define PHP_ENCHANT_VERSION/ {print $3}' ext/enchant/php_enchant.h | xargs)
+if test "$ver" != "PHP_VERSION"; then
        exit 1
 fi
 ver=$(awk '/#define PHP_HASH_VERSION/ {print $3}' ext/hash/php_hash.h | xargs)
@@ -2229,6 +2227,10 @@ fi
 export PROG_SENDMAIL="/usr/lib/sendmail"
 export CPPFLAGS="-DDEBUG_FASTCGI -DHAVE_STRNDUP %{rpmcppflags} \
        -I%{_includedir}/xmlrpc-epi"
+%if %{with intl}
+# icu 59+ C++ API requires C++ >= 11
+CXXFLAGS="%{rpmcxxflags} -std=c++11"
+%endif
 
 sapis="
 cli
@@ -2262,34 +2264,37 @@ for sapi in $sapis; do
        sapi_args=''
        case $sapi in
        cgi-fcgi)
-               sapi_args='--disable-cli'
+               sapi_args='--enable-cgi'
        ;;
        cli)
-               sapi_args='--disable-cgi %{?with_gcov:--enable-gcov}'
+               sapi_args='--enable-cli %{?with_gcov:--enable-gcov}'
        ;;
        fpm)
-               sapi_args='--disable-cli --disable-cgi --enable-fpm'
+               sapi_args='--enable-fpm'
                ;;
        embed)
-               sapi_args='--disable-cli --disable-cgi --enable-embed'
+               sapi_args='--enable-embed'
                ;;
        apxs2)
                ver=$(rpm -q --qf '%{V}' apache-devel)
-               sapi_args="--disable-cli --disable-cgi --with-apxs2=%{apxs2} --with-apache-version=$ver"
+               sapi_args="--with-apxs2=%{apxs2} --with-apache-version=$ver"
        ;;
        litespeed)
-               sapi_args='--disable-cli --disable-cgi --with-litespeed'
+               sapi_args='--with-litespeed'
        ;;
        phpdbg)
-               sapi_args='--disable-cli --disable-cgi --enable-phpdbg %{?debug:--enable-phpdbg-debug}'
+               sapi_args='--enable-phpdbg %{?debug:--enable-phpdbg-debug}'
        ;;
        milter)
-               sapi_args='--disable-cli --disable-cgi --with-milter'
+               sapi_args='--with-milter'
        ;;
        esac
 
        %configure \
        EXTRA_LDFLAGS="%{rpmldflags}" \
+       --disable-cgi \
+       --disable-cli \
+       --disable-phpdbg \
        $sapi_args \
 %if "%{!?configure_cache:0}%{?configure_cache}" == "0"
        --cache-file=config.cache \
@@ -2298,6 +2303,7 @@ for sapi in $sapis; do
        --with-config-file-path=%{_sysconfdir} \
        --with-config-file-scan-dir=%{_sysconfdir}/conf.d \
        --with-system-tzdata \
+       %{?with_argon2:--with-password-argon2} \
        --%{!?debug:dis}%{?debug:en}able-debug \
        %{?with_zts:--enable-maintainer-zts} \
        --enable-inline-optimization \
@@ -2310,10 +2316,10 @@ for sapi in $sapis; do
        %{__enable_disable exif exif shared} \
        %{__enable_disable fileinfo fileinfo shared} \
        %{__enable_disable ftp ftp shared} \
-       --enable-gd-native-ttf \
        %{?with_intl:--enable-intl=shared} \
        --enable-libxml \
        %{__enable_disable mbstring mbstring shared,all} \
+       --with-onig=/usr \
        --enable-mbregex \
        %{__enable_disable pcntl pcntl shared} \
        %{__enable_disable pdo pdo shared} \
@@ -2349,6 +2355,7 @@ for sapi in $sapis; do
        --enable-sysvshm=shared \
        --enable-soap=shared \
        --enable-sockets=shared \
+       %{__with_without sodium sodium shared} \
        --enable-tokenizer=shared \
        %{?with_wddx:--enable-wddx=shared} \
        --enable-xml=shared \
@@ -2367,7 +2374,6 @@ for sapi in $sapis; do
        %{?with_interbase:--with-interbase=shared%{!?with_interbase_inst:,/usr}} \
        --with-jpeg-dir=/usr \
        %{?with_ldap:--with-ldap=shared --with-ldap-sasl} \
-       %{__with_without mcrypt mcrypt shared} \
        %{?with_mm:--with-mm} \
        %{?with_mysqlnd:--enable-mysqlnd=shared} \
        %{?with_mysqli:--with-mysqli=shared,%{!?with_mysqlnd:/usr/bin/mysql_config}%{?with_mysqlnd:mysqlnd}} \
@@ -2391,7 +2397,7 @@ for sapi in $sapis; do
        %{?with_tidy:--with-tidy=shared} \
        %{?with_odbc:--with-unixODBC=shared,/usr} \
        %{__with_without xmlrpc xmlrpc shared,/usr} \
-       --with-xsl=shared \
+       %{?with_xsl:--with-xsl=shared} \
        --with-zlib=shared \
        --with-zlib-dir=shared,/usr \
        %{?with_system_libzip:--with-libzip} \
@@ -2487,6 +2493,7 @@ generate_inifiles() {
        done
 }
 generate_inifiles
+cp -p %{_sourcedir}/opcache.ini conf.d
 
 # Check that the module inner-dependencies are intact
 PHP=./sapi/cli/php EXTENSION_DIR=modules CONFIG_DIR=conf.d ./dep-tests.sh > dep-tests.log
@@ -2842,7 +2849,6 @@ fi \
 %extension_scripts json
 %extension_scripts ldap
 %extension_scripts mbstring
-%extension_scripts mcrypt
 %extension_scripts mysqli
 %extension_scripts mysqlnd
 %extension_scripts oci8
@@ -2869,6 +2875,7 @@ fi \
 %extension_scripts snmp
 %extension_scripts soap
 %extension_scripts sockets
+%extension_scripts sodium
 %extension_scripts spl
 %extension_scripts sqlite3
 %extension_scripts sysvmsg
@@ -2905,9 +2912,12 @@ fi
 %files -n apache-mod_%{name}
 %defattr(644,root,root,755)
 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/httpd/conf.d/*_mod_php.conf
+%attr(755,root,root) %{_libdir}/apache/mod_php.so
+
+%files -n apache-mod_%{name}-core
+%defattr(644,root,root,755)
 %dir %{_sysconfdir}/apache2handler.d
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/php-apache2handler.ini
-%attr(755,root,root) %{_libdir}/apache/mod_php.so
 %attr(755,root,root) %{_libdir}/apache/libphp7-*.*.so
 %endif
 
@@ -2975,7 +2985,7 @@ fi
 
 %files common
 %defattr(644,root,root,755)
-%doc CREDITS EXTENSIONS LICENSE NEWS README.namespaces UPGRADING* Zend/{LICENSE.Zend,ZEND_CHANGES} php.ini-*
+%doc CREDITS EXTENSIONS LICENSE NEWS UPGRADING* Zend/{LICENSE.Zend,README*} php.ini-*
 %dir %{_sysconfdir}
 %dir %{_sysconfdir}/conf.d
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/php.ini
@@ -3180,14 +3190,6 @@ fi
 %attr(755,root,root) %{php_extensiondir}/mbstring.so
 %endif
 
-%if %{with mcrypt}
-%files mcrypt
-%defattr(644,root,root,755)
-%doc ext/mcrypt/{CREDITS,TODO}
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/mcrypt.ini
-%attr(755,root,root) %{php_extensiondir}/mcrypt.so
-%endif
-
 %if %{with mysqli}
 %files mysqli
 %defattr(644,root,root,755)
@@ -3415,6 +3417,14 @@ fi
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/sockets.ini
 %attr(755,root,root) %{php_extensiondir}/sockets.so
 
+%if %{with sodium}
+%files sodium
+%defattr(644,root,root,755)
+%doc ext/sodium/{README.md,CREDITS}
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/sodium.ini
+%attr(755,root,root) %{php_extensiondir}/sodium.so
+%endif
+
 %files spl
 %defattr(644,root,root,755)
 %doc ext/spl/{CREDITS,README,TODO}
@@ -3514,11 +3524,13 @@ fi
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/xmlwriter.ini
 %attr(755,root,root) %{php_extensiondir}/xmlwriter.so
 
+%if %{with xsl}
 %files xsl
 %defattr(644,root,root,755)
 %doc ext/xsl/CREDITS
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/xsl.ini
 %attr(755,root,root) %{php_extensiondir}/xsl.so
+%endif
 
 %files zip
 %defattr(644,root,root,755)
This page took 0.063314 seconds and 4 git commands to generate.