]> git.pld-linux.org Git - packages/php.git/blobdiff - php.spec
- release 2, rebuild against icu 64
[packages/php.git] / php.spec
index 7afc51d0e47b3fe9616b5870e5e92d8d8c438f34..0ed22ff9ac2211eb9642a9196b434f52dbd89d48 100644 (file)
--- a/php.spec
+++ b/php.spec
 %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
+%bcond_with    debug           # Zend Debug Build
 # - SAPI
 %bcond_without apache2         # disable building Apache 2.x SAPI
 %bcond_without cgi             # disable CGI/FCGI SAPI
@@ -150,7 +150,7 @@ 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.1.3
+Version:       7.1.28
 Release:       2
 Epoch:         4
 # All files licensed under PHP version 3.01, except
@@ -158,8 +158,8 @@ Epoch:              4
 # 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: d604d688be17f4a05b99dbb7fb9581f4
+Source0:       https://php.net/distributions/%{orgname}-%{version}.tar.xz
+# Source0-md5: 578999c52c48316d6d95597c65c66310
 Source2:       %{orgname}-mod_php.conf
 Source3:       %{orgname}-cgi-fcgi.ini
 Source4:       %{orgname}-apache.ini
@@ -194,9 +194,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 +201,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
@@ -218,11 +214,9 @@ 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
-Patch73:       php-pdo-ssl.patch
 URL:           http://php.net/
 %{?with_interbase:%{!?with_interbase_inst:BuildRequires:       Firebird-devel >= 1.0.2.908-2}}
 %{?with_pspell:BuildRequires:  aspell-devel >= 2:0.50.0}
@@ -265,8 +259,8 @@ BuildRequires:      libxslt-devel >= 1.1.0
 %{?with_system_libzip:BuildRequires:   libzip-devel >= 0.10.1-2}
 %{?with_snmp:%{?with_tests:BuildRequires:      mibs-net-snmp}}
 %{?with_mm:BuildRequires:      mm-devel >= 1.3.0}
-%{!?with_pdo_mysql:BuildRequires:      mysql-devel}
 %{!?with_mysqli:BuildRequires: mysql-devel >= 4.1.13}
+%{!?with_pdo_mysql:BuildRequires:      mysql-devel}
 %{?with_snmp:BuildRequires:    net-snmp-devel >= 5.3}
 %{?with_ldap:BuildRequires:    openldap-devel >= 2.3.0}
 %if %{with openssl} || %{with ldap}
@@ -313,18 +307,18 @@ BuildRoot:        %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 # 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.5.0
 %define                pharver         2.0.2
-%define                sqlite3ver      0.7-dev
+%define                sqlite3ver      %{version}
 %define                zipver          1.13.5
 %define                phpdbgver       0.5.0
 
 %define                _zend_zts               %{!?with_zts:0}%{?with_zts:1}
-%define                php_debug               %{!?debug:0}%{?debug:1}
+%define                php_debug               %{!?with_debug:0}%{?with_debug:1}
 
 %if %{with gcov}
 %undefine      with_ccache
@@ -389,20 +383,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
@@ -618,6 +625,8 @@ Obsoletes:  php54-devel
 Obsoletes:     php55-devel
 Obsoletes:     php56-devel
 Obsoletes:     php70-devel
+Obsoletes:     php72-devel
+Obsoletes:     php73-devel
 
 %description devel
 The php-devel package lets you compile dynamic extensions to PHP.
@@ -1969,7 +1978,7 @@ Moduł PHP umożliwiający używanie kompresji zlib.
 cp -p php.ini-production php.ini
 %patch0 -p1
 %patch1 -p1
-#%patch2 -p1 NEEDS PORTING
+%patch2 -p1
 %patch3 -p1
 %patch4 -p1
 %patch5 -p1
@@ -1993,35 +2002,13 @@ 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
@@ -2038,7 +2025,6 @@ exit 1
 %patch70 -p1
 %patch71 -p1
 %patch72 -p1
-%patch73 -p1
 
 %{__sed} -i -e '/PHP_ADD_LIBRARY_WITH_PATH/s#xmlrpc,#xmlrpc-epi,#' ext/xmlrpc/config.m4
 
@@ -2179,8 +2165,8 @@ 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
@@ -2209,10 +2195,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)
@@ -2242,6 +2226,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
@@ -2314,7 +2302,7 @@ for sapi in $sapis; do
        --with-config-file-path=%{_sysconfdir} \
        --with-config-file-scan-dir=%{_sysconfdir}/conf.d \
        --with-system-tzdata \
-       --%{!?debug:dis}%{?debug:en}able-debug \
+       --%{!?with_debug:dis}%{?with_debug:en}able-debug \
        %{?with_zts:--enable-maintainer-zts} \
        --enable-inline-optimization \
        %{__enable_disable bcmath bcmath shared} \
@@ -2493,6 +2481,8 @@ generate_inifiles() {
                [ "$mod" = "spl" ] && conf="SPL.ini"
                # session needs to be loaded before php-pecl-http, php-pecl-memcache, php-pecl-session_mysql
                [ "$mod" = "session" ] && conf="Session.ini"
+               # hash needs to be loaded before mysqlnd
+               [ "$mod" = "hash" ] && conf="Hash.ini"
                # mysqlnd needs to be loaded before mysqli,pdo_mysqli
                [ "$mod" = "mysqlnd" ] && conf="MySQLND.ini"
                echo "+ $conf"
@@ -2921,9 +2911,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
 
@@ -2991,7 +2984,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 README.namespaces UPGRADING* Zend/{LICENSE.Zend,ZEND_CHANGES} php.ini-* .gdbinit
 %dir %{_sysconfdir}
 %dir %{_sysconfdir}/conf.d
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/php.ini
@@ -3136,7 +3129,7 @@ fi
 %files hash
 %defattr(644,root,root,755)
 %doc ext/hash/{CREDITS,README}
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/hash.ini
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/Hash.ini
 %attr(755,root,root) %{php_extensiondir}/hash.so
 %endif
 
This page took 0.048249 seconds and 4 git commands to generate.