]> git.pld-linux.org Git - packages/php.git/blobdiff - php.spec
- release 15 (by relup.sh)
[packages/php.git] / php.spec
index ed4182935d1085534f40faa2a92fe75126272216..d84ded2da09c0180503ac69708b3e8df69408fc1 100644 (file)
--- a/php.spec
+++ b/php.spec
 #
 # Conditional build:
 %bcond_with    interbase_inst  # use InterBase install., not Firebird  (BR: proprietary libs)
-%bcond_with    oci8            # with Oracle oci8 extension module     (BR: proprietary libs)
-%bcond_with    instantclient   # build Oracle oci8 extension module against oracle-instantclient package
+%bcond_with    oci             # with Oracle oci8 extension module     (BR: proprietary libs)
+%bcond_without instantclient   # build Oracle oci8 extension module against oracle-instantclient package
 %bcond_with    system_gd       # with system gd (we prefer internal since it enables few more features)
 %bcond_with    system_libzip   # with system libzip (reported broken currently)
-%bcond_without default_php     # use this PHP as default PHP in distro
+%bcond_with    default_php     # use this PHP as default PHP in distro
 %bcond_without curl            # without CURL extension module
 %bcond_without filter          # without filter extension module
 %bcond_without enchant         # without Enchant extension module
@@ -42,7 +42,7 @@
 %bcond_without litespeed       # build litespeed module
 %bcond_without ldap            # without LDAP extension module
 %bcond_without mhash           # without mhash extension (supported by hash extension)
-%bcond_without mm              # without mm support for session storage
+%bcond_with    mm              # without mm support for session storage
 %bcond_without mssql           # without MS SQL extension module
 # don't turn it on by default; see TODO item for mysqlnd in this spec
 %bcond_with    mysqlnd         # with mysqlnd support in mysql related extensions
 %undefine      with_mm
 %endif
 
-%ifnarch %{ix86} %{x8664} sparc sparcv9 alpha
+%ifnarch %{ix86} %{x8664} x32 sparc sparcv9 alpha
 # ppc disabled (broken on th-ppc)
 %undefine      with_interbase
 %endif
 
-%ifnarch %{ix86} %{x8664}
+%ifnarch %{ix86} %{x8664} x32
 # unsupported, see sapi/cgi/fpm/fpm_atomic.h
 %undefine      with_fpm
 %endif
@@ -119,7 +119,7 @@ ERROR: You need to select at least one Apache SAPI to build shared modules.
 %endif
 %endif
 
-%define                rel     7
+%define                rel     15
 %define                orgname php
 %define                ver_suffix 53
 %define                php_suffix %{!?with_default_php:%{ver_suffix}}
@@ -130,19 +130,20 @@ Summary(pt_BR.UTF-8):     A linguagem de script PHP
 Summary(ru.UTF-8):     PHP Версии 5 - язык препроцессирования HTML-файлов, выполняемый на сервере
 Summary(uk.UTF-8):     PHP Версії 5 - мова препроцесування HTML-файлів, виконувана на сервері
 Name:          %{orgname}%{php_suffix}
-Version:       5.3.27
+Version:       5.3.29
 Release:       %{rel}%{?with_type_hints:.th}%{?with_oci8:.oci}
 Epoch:         4
-License:       PHP
+# 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://www.php.net/distributions/%{orgname}-%{version}.tar.bz2
-# Source0-md5: 25ae23a5b9615fe8d33de5b63e1bb788
+# Source0-md5: 9469e240cbe6ac865aeaec89b253dd30
 Source2:       %{orgname}-mod_%{orgname}.conf
 Source3:       %{orgname}-cgi-fcgi.ini
 Source4:       %{orgname}-apache.ini
 Source5:       %{orgname}-cli.ini
-# Taken from: http://browsers.garykeith.com/downloads.asp
-Source9:       %{orgname}_browscap.ini
 Source10:      %{orgname}-fpm.init
 Source11:      %{orgname}-fpm.logrotate
 Source12:      %{orgname}-branch.sh
@@ -165,6 +166,7 @@ Patch11:    embed.patch
 %if %{with type_hints}
 Patch12:       http://ilia.ws/patch/type_hint_53_v2.txt
 %endif
+Patch13:       bug-test-pcntl-55479.patch
 Patch14:       %{orgname}-no_pear_install.patch
 Patch15:       %{orgname}-zlib.patch
 Patch17:       %{orgname}-readline.patch
@@ -208,8 +210,33 @@ Patch64:   %{orgname}-m4.patch
 Patch65:       system-libzip.patch
 Patch66:       %{orgname}-db.patch
 Patch67:       php-litespeed.patch
-Patch68:       mysql-lib-ver-mismatch.patch
+Patch68:       x32.patch
 Patch69:       fpm-conf-split.patch
+Patch70:       mysql-lib-ver-mismatch.patch
+# git clone git://github.com/php/php-src.git && git checkout PHP_5_6
+# git diff php-5.3.29..PHP-5.6 ./ext/fileinfo/libmagic > ~/rpm/packages/php/php-fileinfo.patch
+# git diff php-5.3.29..PHP-5.6 ./ext/fileinfo/config.m4 >> ~/rpm/packages/php/php-fileinfo.patch
+# git diff php-5.3.29..PHP-5.6 ./ext/fileinfo/Makefile.frag >> ~/rpm/packages/php/php-fileinfo.patch
+# git diff php-5.3.29..PHP-5.6 ./ext/fileinfo/data_file.c >> ~/rpm/packages/php/php-fileinfo.patch
+Patch71:       php-fileinfo.patch
+# Patch71-md5: 771e4934132c5f5c968248c954d1ef6e
+# Fixes for security bugs
+# https://repo.webtatic.com/yum/centos/5/SRPMS/repoview/php.html
+# also from RHEL6/CentOS7
+Patch220:      php-5.3.3-CVE-2011-4153.patch
+
+Patch247:      php-5.3.3-CVE-2014-2497.patch
+
+Patch249:      php-5.3.29-CVE-2014-3597.patch
+Patch250:      php-5.3.3-CVE-2014-4698.patch
+Patch251:      php-5.3.3-CVE-2014-4670.patch
+Patch252:      php-5.3.3-CVE-2014-3668.patch
+Patch253:      php-5.3.3-CVE-2014-3669.patch
+Patch254:      php-5.3.3-CVE-2014-3670.patch
+
+Patch256:      php-5.3.29-CVE-2014-8142.patch
+Patch257:      php-5.3.29-CVE-2015-0231.patch
+Patch258:      php-5.3.29-CVE-2015-0232.patch
 URL:           http://www.php.net/
 %{?with_interbase:%{!?with_interbase_inst:BuildRequires:       Firebird-devel >= 1.0.2.908-2}}
 %{?with_pspell:BuildRequires:  aspell-devel >= 2:0.50.0}
@@ -222,7 +249,6 @@ BuildRequires:      cyrus-sasl-devel
 BuildRequires: db-devel >= 4.0
 BuildRequires: elfutils-devel
 %{?with_enchant:BuildRequires: enchant-devel >= 1.1.3}
-#BuildRequires:        fcgi-devel
 BuildRequires: file
 %{?with_kerberos5:BuildRequires:       heimdal-devel}
 %{?with_system_libzip:BuildRequires:   libzip-devel >= 0.10-3}
@@ -245,13 +271,11 @@ BuildRequires:    libjpeg-devel
 BuildRequires: libltdl-devel >= 1.4
 BuildRequires: libmcrypt-devel >= 2.4.4
 BuildRequires: libpng-devel >= 1.0.8
-#BuildRequires:        libtiff-devel
 %if "%{pld_release}" != "ac"
 BuildRequires: libtool >= 2:2.2
 %else
 BuildRequires: libtool >= 1.4.3
 %endif
-#BuildRequires:        libwrap-devel
 BuildRequires: libxml2-devel >= 1:2.7.6-4
 BuildRequires: libxslt-devel >= 1.1.0
 %{?with_mm:BuildRequires:      mm-devel >= 1.3.0}
@@ -262,7 +286,7 @@ BuildRequires:      openssl-devel >= 0.9.7d
 %{?with_gcov:BuildRequires:    lcov}
 %{?with_snmp:%{?with_tests:BuildRequires:      mibs-net-snmp}}
 %{?with_snmp:BuildRequires:    net-snmp-devel >= 5.0.7}
-%{?with_instantclient:BuildRequires:   oracle-instantclient-devel}
+%{?with_oci:%{?with_instantclient:BuildRequires:       oracle-instantclient-devel}}
 BuildRequires: pam-devel
 %{?with_pcre:BuildRequires:    pcre-devel >= 8.10}
 BuildRequires: pkgconfig
@@ -290,9 +314,6 @@ BuildRequires:      apache-devel >= 2.0.52-2
 BuildRequires: apr-devel >= 1:1.0.0
 BuildRequires: apr-util-devel >= 1:1.0.0
 %endif
-%if %{with fpm}
-#BuildRequires:        judy-devel
-%endif
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                php_sysconfdir          /etc/%{name}
@@ -323,7 +344,7 @@ BuildRoot:  %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 %undefine      with_ccache
 %endif
 
-%if %{with oci8}
+%if %{with oci}
 # ORACLE_HOME is required for oci8 ext to build
 %define _preserve_env %_preserve_env_base ORACLE_HOME
 %endif
@@ -385,12 +406,12 @@ PHP - це мова написання скриптів, що вбудовуют
 Summary:       PHP DSO module for Apache 1.3.x
 Summary(pl.UTF-8):     Moduł DSO (Dynamic Shared Object) PHP dla Apache 1.3.x
 Group:         Development/Languages/PHP
-Requires(triggerpostun):       sed >= 4.0
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      apache1(EAPI) >= 1.3.33-2
 Requires:      apache1-mod_mime
 Provides:      webserver(php) = %{version}
 Obsoletes:     apache-mod_php < 1:4.1.1
+Obsoletes:     apache1-mod_php < 4:5.3.28-7
 Obsoletes:     phpfi
 
 %description -n apache1-mod_%{name}
@@ -407,6 +428,7 @@ Requires:   %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      apache(modules-api) = %{apache_modules_api}
 Requires:      apache-mod_mime
 Provides:      webserver(php) = %{version}
+Obsoletes:     apache-mod_php < 4:5.3.28-7
 Obsoletes:     phpfi
 
 %description -n apache-mod_%{name}
@@ -420,7 +442,9 @@ Summary:    PHP for litespeed HTTP server
 Summary(pl.UTF-8):     PHP dla serwera HTTP litespeed
 Group:         Development/Languages/PHP
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
+Provides:      php(litespeed)
 Provides:      webserver(php) = %{version}
+Obsoletes:     php-litespeed < 4:5.3.28-7
 
 %description litespeed
 PHP for litespeed HTTP server.
@@ -437,6 +461,7 @@ Provides:   %{name}-fcgi = %{epoch}:%{version}-%{release}
 Provides:      php(cgi)
 Provides:      php(fcgi)
 Provides:      webserver(php) = %{version}
+Obsoletes:     php-cgi < 4:5.3.28-7
 Obsoletes:     php-fcgi < 4:5.3.0
 %if "%{pld_release}" != "ac"
 Conflicts:     logrotate < 3.8.0
@@ -453,6 +478,7 @@ Summary:    PHP as CLI interpreter
 Summary(pl.UTF-8):     PHP jako interpreter działający z linii poleceń
 Group:         Development/Languages/PHP
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
+Obsoletes:     php-cli < 4:5.3.28-7
 
 %description cli
 PHP as CLI interpreter.
@@ -465,6 +491,7 @@ Summary:    PHP library for embedding in applications
 Summary(pl.UTF-8):     Biblioteka PHP do osadzania w aplikacjach
 Group:         Libraries
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
+Obsoletes:     php-embedded < 4:5.3.28-7
 
 %description embedded
 The php-embedded package contains a library which can be embedded into
@@ -480,6 +507,7 @@ Summary(pl.UTF-8):  Dowiązanie symboliczne /usr/bin/php
 Group:         Development/Languages/PHP
 Requires:      %{name}-cli = %{epoch}:%{version}-%{release}
 Obsoletes:     /usr/bin/php
+Obsoletes:     php-program < 4:5.3.28-7
 
 %description program
 Package providing /usr/bin/php symlink to PHP CLI.
@@ -498,8 +526,10 @@ Requires(pre):     /bin/id
 Requires(pre): /usr/sbin/useradd
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      rc-scripts
+Provides:      php(fpm)
 Provides:      user(http)
 Provides:      webserver(php) = %{version}
+Obsoletes:     php-fpm < 4:5.3.28-7
 
 %description fpm
 PHP FastCGI Process Manager.
@@ -537,12 +567,13 @@ Provides: %{name}-standard
 Provides:      php(core) = %{version}
 Provides:      php(date)
 Provides:      php(ereg)
-Provides:      php(hash)
 Provides:      php(libxml)
 Provides:      php(reflection)
 Provides:      php(standard)
 %{!?with_mysqlnd:Obsoletes:    php-mysqlnd}
 %{?with_pcre:%requires_ge_to   pcre pcre-devel}
+Suggests:      browscap
+Obsoletes:     php-common < 4:5.3.28-7
 Obsoletes:     php-pecl-domxml
 Conflicts:     php4-common < 3:4.4.4-8
 Conflicts:     rpm < 4.4.2-0.2
@@ -579,11 +610,13 @@ Requires: libtool
 %{?with_embed:Requires:        %{name}-embedded = %{epoch}:%{version}-%{release}}
 %{?with_pcre:Requires: pcre-devel >= 8.10}
 Requires:      shtool
+Obsoletes:     php-devel
 Obsoletes:     php-pear-devel
 Obsoletes:     php4-devel
 Obsoletes:     php52-devel
 Obsoletes:     php54-devel
 Obsoletes:     php55-devel
+Obsoletes:     php56-devel
 
 %description devel
 The php-devel package lets you compile dynamic extensions to PHP.
@@ -625,6 +658,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.bc.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(bcmath)
+Obsoletes:     php-bcmath < 4:5.3.28-7
 
 %description bcmath
 This is a dynamic shared object (DSO) for PHP that will add bc style
@@ -643,6 +677,7 @@ Requires:   %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(bz2) = %{bz2ver}
 Provides:      php(bzip2)
 Provides:      php-bzip2 = %{epoch}:%{version}-%{release}
+Obsoletes:     php-bz2 < 4:5.3.28-7
 Obsoletes:     php-bzip2 < 4:5.2.14-3
 Obsoletes:     php-pecl-bz2 < %{bz2ver}
 
@@ -660,6 +695,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.calendar.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(calendar)
+Obsoletes:     php-calendar < 4:5.3.28-7
 
 %description calendar
 This is a dynamic shared object (DSO) for PHP that will add calendar
@@ -675,6 +711,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.ctype.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(ctype)
+Obsoletes:     php-ctype < 4:5.3.28-7
 
 %description ctype
 This is a dynamic shared object (DSO) for PHP that will add ctype
@@ -690,6 +727,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.curl.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(curl)
+Obsoletes:     php-curl < 4:5.3.28-7
 
 %description curl
 This is a dynamic shared object (DSO) for PHP that will add curl
@@ -705,6 +743,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.dba.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(dba)
+Obsoletes:     php-dba < 4:5.3.28-7
 
 %description dba
 This is a dynamic shared object (DSO) for PHP that will add flat-file
@@ -724,6 +763,7 @@ Provides:   php(dom)
 # it has some compatibility functions
 Provides:      %{name}-domxml = %{epoch}:%{version}-%{release}
 Provides:      php(domxml)
+Obsoletes:     php-dom < 4:5.3.28-7
 Obsoletes:     php-domxml <= 3:4.3.8-1
 
 %description dom
@@ -740,6 +780,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.exif.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(enchant) = %{enchantver}
+Obsoletes:     php-enchant < 4:5.3.28-7
 Obsoletes:     php-pecl-enchant < %{enchantver}
 
 %description enchant
@@ -769,6 +810,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.exif.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(exif)
+Obsoletes:     php-exif < 4:5.3.28-7
 
 %description exif
 This is a dynamic shared object (DSO) for PHP that will add EXIF tags
@@ -785,6 +827,7 @@ URL:                http://www.php.net/manual/en/book.fileinfo.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pcre = %{epoch}:%{version}-%{release}
 Provides:      php(fileinfo) = %{fileinfover}
+Obsoletes:     php-fileinfo < 4:5.3.28-7
 Obsoletes:     php-mime_magic
 Obsoletes:     php-pecl-fileinfo < %{fileinfover}
 
@@ -811,6 +854,7 @@ URL:                http://www.php.net/manual/en/book.filter.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pcre = %{epoch}:%{version}-%{release}
 Provides:      php(filter)
+Obsoletes:     php-filter < 4:5.3.28-7
 Obsoletes:     php-pecl-filter
 
 %description filter
@@ -834,6 +878,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.ftp.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(ftp)
+Obsoletes:     php-ftp < 4:5.3.28-7
 
 %description ftp
 This is a dynamic shared object (DSO) for PHP that will add FTP
@@ -854,6 +899,7 @@ Requires:   gd(gif)
 Requires:      gd(imagerotate) = 5.2.0
 %endif
 Provides:      php(gd)
+Obsoletes:     php-gd < 4:5.3.28-7
 
 %description gd
 This is a dynamic shared object (DSO) for PHP that will add GD
@@ -870,6 +916,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.gettext.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(gettext)
+Obsoletes:     php-gettext < 4:5.3.28-7
 
 %description gettext
 This is a dynamic shared object (DSO) for PHP that will add gettext
@@ -885,6 +932,7 @@ Group:              Libraries
 URL:           http://www.php.net/manual/en/book.gmp.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(gmp)
+Obsoletes:     php-gmp < 4:5.3.28-7
 
 %description gmp
 This is a dynamic shared object (DSO) for PHP that will add arbitrary
@@ -906,6 +954,7 @@ Provides:   php(mhash)
 Provides:      php-mhash = %{epoch}:%{version}-%{release}
 Obsoletes:     php-mhash < 4:5.3.0
 %endif
+Obsoletes:     php-hash < 4:5.3.28-7
 Obsoletes:     php-pecl-hash < %{hashver}
 
 %description hash
@@ -925,6 +974,7 @@ Requires:   %{_libdir}/gconv
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      iconv
 Provides:      php(iconv)
+Obsoletes:     php-iconv < 4:5.3.28-7
 
 %description iconv
 This is a dynamic shared object (DSO) for PHP that will add iconv
@@ -943,6 +993,7 @@ Requires:   %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pcre = %{epoch}:%{version}-%{release}
 Requires:      imap-lib >= 1:2007e-2
 Provides:      php(imap)
+Obsoletes:     php-imap < 4:5.3.28-7
 
 %description imap
 This is a dynamic shared object (DSO) for PHP that will add IMAP
@@ -962,6 +1013,7 @@ URL:               http://www.php.net/manual/en/book.ibase.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(interbase)
 %{?with_interbase_inst:Autoreq:        false}
+Obsoletes:     php-interbase < 4:5.3.28-7
 
 %description interbase
 This is a dynamic shared object (DSO) for PHP that will add InterBase
@@ -977,6 +1029,7 @@ Group:             Libraries
 URL:           http://www.php.net/intl
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(intl) = %{intlver}
+Obsoletes:     php-intl < 4:5.3.28-7
 Obsoletes:     php-pecl-intl < %{intlver}
 
 %description intl
@@ -998,6 +1051,7 @@ Group:             Libraries
 URL:           http://www.php.net/manual/en/book.json.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(json) = %{jsonver}
+Obsoletes:     php-json < 4:5.3.28-7
 Obsoletes:     php-pecl-json < %{jsonver}
 
 %description json
@@ -1016,6 +1070,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.ldap.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(ldap)
+Obsoletes:     php-ldap < 4:5.3.28-7
 
 %description ldap
 This is a dynamic shared object (DSO) for PHP that will add LDAP
@@ -1034,6 +1089,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.mbstring.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(mbstring)
+Obsoletes:     php-mbstring < 4:5.3.28-7
 
 %description mbstring
 This is a dynamic shared object (DSO) for PHP that will add multibyte
@@ -1049,6 +1105,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.mcrypt.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 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
@@ -1064,6 +1121,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.mssql.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(mssql)
+Obsoletes:     php-mssql < 4:5.3.28-7
 
 %description mssql
 This is a dynamic shared object (DSO) for PHP that will add MS SQL
@@ -1082,6 +1140,7 @@ URL:              http://www.php.net/manual/en/book.mysql.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 %{?with_mysqlnd:Requires:      %{name}-mysqlnd = %{epoch}:%{version}-%{release}}
 Provides:      php(mysql)
+Obsoletes:     php-mysql < 4:5.3.28-7
 
 %description mysql
 This is a dynamic shared object (DSO) for PHP that will add MySQL
@@ -1102,6 +1161,7 @@ Requires: %{name}-common = %{epoch}:%{version}-%{release}
 %{?with_mysqlnd:Requires:      %{name}-mysqlnd = %{epoch}:%{version}-%{release}}
 Requires:      %{name}-spl = %{epoch}:%{version}-%{release}
 Provides:      php(mysqli)
+Obsoletes:     php-mysqli < 4:5.3.28-7
 
 %description mysqli
 This is a dynamic shared object (DSO) for PHP that will add MySQLi
@@ -1120,6 +1180,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.mysqlnd.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(mysqlnd)
+Obsoletes:     php-mysqlnd < 4:5.3.28-7
 
 %description mysqlnd
 MySQL Native Driver is a replacement for the MySQL Client Library
@@ -1157,6 +1218,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.oci8.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(oci8)
+Obsoletes:     php-oci8 < 4:5.3.28-7
 AutoReq:       false
 
 %description oci8
@@ -1176,6 +1238,7 @@ URL:              http://www.php.net/manual/en/book.uodbc.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      unixODBC >= 2.1.1-3
 Provides:      php(odbc)
+Obsoletes:     php-odbc < 4:5.3.28-7
 
 %description odbc
 This is a dynamic shared object (DSO) for PHP that will add ODBC
@@ -1194,6 +1257,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.openssl.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(openssl)
+Obsoletes:     php-openssl < 4:5.3.28-7
 
 %description openssl
 This is a dynamic shared object (DSO) for PHP that will add OpenSSL
@@ -1209,6 +1273,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.pcntl.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(pcntl)
+Obsoletes:     php-pcntl < 4:5.3.28-7
 
 %description pcntl
 This is a dynamic shared object (DSO) for PHP that will add process
@@ -1225,6 +1290,7 @@ Summary(pl.UTF-8):        Moduł PCRE dla PHP
 Group:         Libraries
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(pcre)
+Obsoletes:     php-pcre < 4:5.3.28-7
 
 %description pcre
 This is a dynamic shared object (DSO) for PHP that will add Perl
@@ -1242,6 +1308,7 @@ URL:              http://www.php.net/manual/en/book.pdo.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-spl = %{epoch}:%{version}-%{release}
 Provides:      php(pdo)
+Obsoletes:     php-pdo < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO
 
 %description pdo
@@ -1259,6 +1326,7 @@ URL:              http://www.php.net/manual/en/ref.pdo-dblib.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(dblib)
+Obsoletes:     php-pdo-dblib < 4:5.3.28-7
 
 %description pdo-dblib
 This is a dynamic shared object (DSO) for PHP that will add PDO
@@ -1276,6 +1344,7 @@ URL:              http://www.php.net/manual/en/ref.pdo-firebird.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-firebird)
+Obsoletes:     php-pdo-firebird < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_FIREBIRD
 
 %description pdo-firebird
@@ -1295,6 +1364,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)
+Obsoletes:     php-pdo-mysql < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_MYSQL
 
 %description pdo-mysql
@@ -1313,6 +1383,7 @@ URL:              http://www.php.net/manual/en/ref.pdo-oci.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-oci)
+Obsoletes:     php-pdo-oci < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_OCI
 
 %description pdo-oci
@@ -1331,6 +1402,7 @@ URL:              http://www.php.net/manual/en/ref.pdo-odbc.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-odbc)
+Obsoletes:     php-pdo-odbc < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_ODBC
 
 %description pdo-odbc
@@ -1350,6 +1422,7 @@ Requires: %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-pgsql)
 Provides:      php-pecl-PDO_PGSQL
+Obsoletes:     php-pdo-pgsql < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_PGSQL < 4:5.2.1-2
 
 %description pdo-pgsql
@@ -1368,6 +1441,7 @@ URL:              http://www.php.net/manual/en/ref.pdo-sqlite.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pdo = %{epoch}:%{version}-%{release}
 Provides:      php(pdo-sqlite)
+Obsoletes:     php-pdo-sqlite < 4:5.3.28-7
 Obsoletes:     php-pecl-PDO_SQLITE
 
 %description pdo-sqlite
@@ -1385,6 +1459,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.pgsql.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(pgsql)
+Obsoletes:     php-pgsql < 4:5.3.28-7
 
 %description pgsql
 This is a dynamic shared object (DSO) for PHP that will add PostgreSQL
@@ -1408,6 +1483,7 @@ Suggests: %{name}-cli
 Suggests:      %{name}-zlib
 Provides:      php(phar) = %{pharver}
 Obsoletes:     php-pecl-phar < %{pharver}
+Obsoletes:     php-phar < 4:5.3.28-7
 Conflicts:     php-ioncube < 4.0.9
 
 %description phar
@@ -1424,6 +1500,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.posix.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(posix)
+Obsoletes:     php-posix < 4:5.3.28-7
 
 %description posix
 This is a dynamic shared object (DSO) for PHP that will add POSIX
@@ -1439,6 +1516,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.pspell.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(pspell)
+Obsoletes:     php-pspell < 4:5.3.28-7
 
 %description pspell
 This is a dynamic shared object (DSO) for PHP that will add pspell
@@ -1456,6 +1534,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.readline.php
 Requires:      %{name}-cli = %{epoch}:%{version}-%{release}
 Provides:      php(readline)
+Obsoletes:     php-readline < 4:5.3.28-7
 
 %description readline
 This PHP module adds support for readline functions (only for cli and
@@ -1472,6 +1551,7 @@ URL:              http://www.php.net/manual/en/book.recode.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      recode >= 3.5d-3
 Provides:      php(recode)
+Obsoletes:     php-recode < 4:5.3.28-7
 
 %description recode
 This is a dynamic shared object (DSO) for PHP that will add recode
@@ -1488,7 +1568,9 @@ Group:            Libraries
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-spl = %{epoch}:%{version}-%{release}
 Suggests:      %{name}-hash = %{epoch}:%{version}-%{release}
+Suggests:      tmpwatch
 Provides:      php(session)
+Obsoletes:     php-session < 4:5.3.28-7
 
 %description session
 This is a dynamic shared object (DSO) for PHP that will add session
@@ -1504,6 +1586,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.shmop.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(shmop)
+Obsoletes:     php-shmop < 4:5.3.28-7
 
 %description shmop
 This is a dynamic shared object (DSO) for PHP that will add Shared
@@ -1520,6 +1603,7 @@ URL:              http://www.php.net/manual/en/book.simplexml.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-spl = %{epoch}:%{version}-%{release}
 Provides:      php(simplexml)
+Obsoletes:     php-simplexml < 4:5.3.28-7
 
 %description simplexml
 This is a dynamic shared object (DSO) for PHP that will add Simple XML
@@ -1536,6 +1620,7 @@ URL:              http://www.php.net/manual/en/book.snmp.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-sockets = %{epoch}:%{version}-%{release}
 Provides:      php(snmp)
+Obsoletes:     php-snmp < 4:5.3.28-7
 
 %description snmp
 This is a dynamic shared object (DSO) for PHP that will add SNMP
@@ -1551,6 +1636,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.soap.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(soap)
+Obsoletes:     php-soap < 4:5.3.28-7
 
 %description soap
 This is a dynamic shared object (DSO) for PHP that will add SOAP/WSDL
@@ -1566,6 +1652,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.sockets.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(sockets)
+Obsoletes:     php-sockets < 4:5.3.28-7
 
 %description sockets
 This is a dynamic shared object (DSO) for PHP that will add sockets
@@ -1583,6 +1670,7 @@ Requires: %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-pcre = %{epoch}:%{version}-%{release}
 Requires:      %{name}-simplexml = %{epoch}:%{version}-%{release}
 Provides:      php(spl)
+Obsoletes:     php-spl < 4:5.3.28-7
 
 %description spl
 This is a dynamic shared object (DSO) for PHP that will add Standard
@@ -1601,6 +1689,7 @@ Requires: %{name}-pdo = %{epoch}:%{version}-%{release}
 Requires:      %{name}-spl = %{epoch}:%{version}-%{release}
 Provides:      php(sqlite) = %{sqlitever}
 Obsoletes:     php-pecl-SQLite < %{sqlitever}
+Obsoletes:     php-sqlite < 4:5.3.28-7
 
 %description sqlite
 SQLite is a C library that implements an embeddable SQL database
@@ -1629,6 +1718,7 @@ Group:            Libraries
 URL:           http://php.net/manual/en/book.sqlite3.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(sqlite3) = %{sqlite3ver}
+Obsoletes:     php-sqlite3 < 4:5.3.28-7
 
 %description sqlite3
 SQLite is a C library that implements an embeddable SQL database
@@ -1658,6 +1748,7 @@ URL:              http://www.php.net/manual/en/book.sybase.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(sybase-ct)
 Obsoletes:     php-sybase
+Obsoletes:     php-sybase-ct < 4:5.3.28-7
 
 %description sybase-ct
 This is a dynamic shared object (DSO) for PHP that will add Sybase and
@@ -1674,6 +1765,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.sem.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(sysvmsg)
+Obsoletes:     php-sysvmsg < 4:5.3.28-7
 
 %description sysvmsg
 This is a dynamic shared object (DSO) for PHP that will add SysV
@@ -1689,6 +1781,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.sem.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(sysvsem)
+Obsoletes:     php-sysvsem < 4:5.3.28-7
 
 %description sysvsem
 This is a dynamic shared object (DSO) for PHP that will add SysV
@@ -1704,6 +1797,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.shmop.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(sysvshm)
+Obsoletes:     php-sysvshm < 4:5.3.28-7
 
 %description sysvshm
 This is a dynamic shared object (DSO) for PHP that will add SysV
@@ -1733,6 +1827,7 @@ URL:              http://www.php.net/manual/en/book.tidy.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      tidy
 Provides:      php(tidy)
+Obsoletes:     php-tidy < 4:5.3.28-7
 
 %description tidy
 This is a dynamic shared object (DSO) for PHP that will add Tidy
@@ -1748,6 +1843,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.tokenizer.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(tokenizer)
+Obsoletes:     php-tokenizer < 4:5.3.28-7
 
 %description tokenizer
 This is a dynamic shared object (DSO) for PHP that will add tokenizer
@@ -1768,6 +1864,7 @@ Requires: %{name}-common = %{epoch}:%{version}-%{release}
 #Requires:     %{name}-session = %{epoch}:%{version}-%{release}
 Requires:      %{name}-xml = %{epoch}:%{version}-%{release}
 Provides:      php(wddx)
+Obsoletes:     php-wddx < 4:5.3.28-7
 
 %description wddx
 This is a dynamic shared object (DSO) for PHP that will add wddx
@@ -1783,6 +1880,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.xml.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(xml)
+Obsoletes:     php-xml < 4:5.3.28-7
 
 %description xml
 This is a dynamic shared object (DSO) for PHP that will add XML
@@ -1800,8 +1898,9 @@ Summary(pl.UTF-8):        Moduł XML Reader dla PHP
 Group:         Libraries
 URL:           http://www.php.net/manual/en/book.xmlreader.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
-Suggests:      %{name}-dom = %{epoch}:%{version}-%{release}
+Requires:      %{name}-dom = %{epoch}:%{version}-%{release}
 Provides:      php(xmlreader)
+Obsoletes:     php-xmlreader < 4:5.3.28-7
 
 %description xmlreader
 This is a dynamic shared object (DSO) for PHP that will add XML Reader
@@ -1822,6 +1921,7 @@ URL:              http://www.php.net/manual/en/book.xmlrpc.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Requires:      %{name}-xml = %{epoch}:%{version}-%{release}
 Provides:      php(xmlrpc)
+Obsoletes:     php-xmlrpc < 4:5.3.28-7
 
 %description xmlrpc
 This is a dynamic shared object (DSO) for PHP that will add XMLRPC
@@ -1838,6 +1938,7 @@ URL:              http://www.php.net/manual/en/book.xmlwriter.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(xmlwriter)
 Obsoletes:     php-pecl-xmlwriter
+Obsoletes:     php-xmlwriter < 4:5.3.28-7
 
 %description xmlwriter
 This extension wraps the libxml xmlWriter API. Represents a writer
@@ -1859,6 +1960,7 @@ Requires: %{name}-dom = %{epoch}:%{version}-%{release}
 Requires:      libxslt >= 1.0.18
 # actually not true, functionality is similar, but API differs
 Provides:      php(xsl)
+Obsoletes:     php-xsl < 4:5.3.28-7
 Obsoletes:     php-xslt <= 3:4.3.8-1
 
 %description xsl
@@ -1877,6 +1979,7 @@ Requires: %{name}-common = %{epoch}:%{version}-%{release}
 %{?with_system_libzip:Requires:        libzip >= 0.10-3}
 Provides:      php(zip) = %{zipver}
 Obsoletes:     php-pecl-zip < %{zipver}
+Obsoletes:     php-zip < 4:5.3.28-7
 
 %description zip
 Zip is an extension to create, modify and read zip files.
@@ -1892,6 +1995,7 @@ Group:            Libraries
 URL:           http://www.php.net/manual/en/book.zlib.php
 Requires:      %{name}-common = %{epoch}:%{version}-%{release}
 Provides:      php(zlib)
+Obsoletes:     php-zlib < 4:5.3.28-7
 
 %description zlib
 This is a dynamic shared object (DSO) for PHP that will add zlib
@@ -1918,6 +2022,7 @@ cp -p php.ini-production php.ini
 %if %{with type_hints}
 %patch12 -p0
 %endif
+%patch13 -p1
 %patch14 -p1
 %patch15 -p1
 %patch17 -p1
@@ -1944,6 +2049,7 @@ cp -p php.ini-production php.ini
 %patch38 -p1
 %patch39 -p1
 %if %{with fpm}
+%patch69 -p1
 %patch41 -p1
 %patch42 -p1
 %endif
@@ -1954,6 +2060,7 @@ cp -p php.ini-production php.ini
 %if %{with suhosin}
 %patch47 -p1
 %endif
+%patch68 -p1
 %patch48 -p1
 %patch49 -p1
 %patch50 -p1
@@ -1971,8 +2078,23 @@ cp -p php.ini-production php.ini
 %{__rm} -r sapi/litespeed
 gzip -dc %{SOURCE15} | tar xf - -C sapi/
 %patch67 -p1
-%patch68 -p1
-%patch69 -p1
+%patch70 -p1
+%patch71 -p1
+
+%patch220 -p1
+
+%patch247 -p1
+
+%patch249 -p1
+%patch250 -p1
+%patch251 -p1
+%patch252 -p1
+%patch253 -p1
+%patch254 -p1
+
+%patch256 -p1
+%patch257 -p1
+%patch258 -p1
 
 sed -i -e '/PHP_ADD_LIBRARY_WITH_PATH/s#xmlrpc,#xmlrpc-epi,#' ext/xmlrpc/config.m4
 
@@ -2105,6 +2227,8 @@ export EXTENSION_DIR="%{php_extensiondir}"
 if [ ! -f _built-conf ]; then
        # now remove Makefile copies
        rm -f Makefile.{cgi-fcgi,fpm,cli,apxs1,apxs2,litespeed}
+       # force regeneration
+       touch Zend/zend_language_parser.y
        %{__libtoolize}
        %{__aclocal}
        cp -f /usr/share/automake/config.* .
@@ -2213,7 +2337,7 @@ for sapi in $sapis; do
        %{?with_mhash:--with-mhash=yes} \
        --with-mysql-sock=/var/lib/mysql/mysql.sock \
        --with-pdo-mysql=shared%{?with_mysqlnd:,mysqlnd} \
-       %{?with_oci8:--with-pdo-oci=shared%{?with_instantclient:,instantclient,%{_libdir}}} \
+       %{?with_oci:--with-pdo-oci=shared%{?with_instantclient:,instantclient,%{_libdir}}} \
        %{?with_odbc:--with-pdo-odbc=shared,unixODBC,/usr} \
        %{?with_pgsql:--with-pdo-pgsql=shared} \
        %{?with_pdo_sqlite:--with-pdo-sqlite=shared,/usr} \
@@ -2254,7 +2378,7 @@ for sapi in $sapis; do
        %{?with_mysqlnd:--with-mysqlnd=shared} \
        --with-mysql=shared%{?with_mysqlnd:,mysqlnd} \
        %{?with_mysqli:--with-mysqli=shared%{?with_mysqlnd:,mysqlnd}} \
-       %{?with_oci8:--with-oci8=shared%{?with_instantclient:,instantclient,%{_libdir}}} \
+       %{?with_oci:--with-oci8=shared%{?with_instantclient:,instantclient,%{_libdir}}} \
        %{?with_openssl:--with-openssl=shared} \
        %{?with_kerberos5:--with-kerberos} \
        %{__with_without pcre pcre-regex /usr} \
@@ -2413,6 +2537,7 @@ install -d $RPM_BUILD_ROOT{%{_libdir}/{php,apache{,1}},%{_sysconfdir}/{apache,cg
 cp -pf php_config.h.cli main/php_config.h
 cp -pf Makefile.cli Makefile
 %{__make} install \
+       phpbuilddir=%{_libdir}/%{name}/build \
        INSTALL_ROOT=$RPM_BUILD_ROOT
 
 # make link relative
@@ -2494,9 +2619,7 @@ ln -s php%{ver_suffix} $RPM_BUILD_ROOT%{_bindir}/php.cli
 %endif
 
 cp -p php.ini $RPM_BUILD_ROOT%{_sysconfdir}/php.ini
-
 cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/php-cli.ini
-cp -p %{SOURCE9} $RPM_BUILD_ROOT%{_sysconfdir}/browscap.ini
 
 %if %{with apache1}
 cp -p %{SOURCE2} $RPM_BUILD_ROOT/etc/apache/conf.d/70_mod_php.conf
@@ -2527,17 +2650,20 @@ install -d $RPM_BUILD_ROOT%{_sysconfdir}/{cgi-fcgi,cli,apache,apache2handler}.d
 mv $RPM_BUILD_ROOT%{_sysconfdir}/{conf.d/readline.ini,cli.d}
 
 # use system automake and {lib,sh}tool
-%if "%{pld_release}" != "ac"
-       ln -snf /usr/share/automake/config.{guess,sub} $RPM_BUILD_ROOT%{_libdir}/php/build
-       for i in libtool.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4; do
-               ln -snf %{_aclocaldir}/${i} $RPM_BUILD_ROOT%{_libdir}/php/build
-       done
-       ln -snf %{_datadir}/libtool/config/ltmain.sh $RPM_BUILD_ROOT%{_libdir}/php/build
-%else
-       ln -snf %{_aclocaldir}/libtool.m4 $RPM_BUILD_ROOT%{_libdir}/php/build
-       ln -snf %{_datadir}/libtool/ltmain.sh $RPM_BUILD_ROOT%{_libdir}/php/build
-%endif
-ln -snf %{_bindir}/shtool $RPM_BUILD_ROOT%{_libdir}/php/build
+ln -snf /usr/share/automake/config.{guess,sub} $RPM_BUILD_ROOT%{_libdir}/%{name}/build
+ln -snf %{_bindir}/shtool $RPM_BUILD_ROOT%{_libdir}/%{name}/build
+for fn in libtool.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4; do
+       f=%{_aclocaldir}/$fn
+       test -f $f || continue
+       ln -snf $f $RPM_BUILD_ROOT%{_libdir}/%{name}/build
+done
+for fn in ltmain.sh config/ltmain.sh build-aux/ltmain.sh; do
+       f=/usr/share/libtool/$fn
+       test -f $f || continue
+       ln -snf $f $RPM_BUILD_ROOT%{_libdir}/%{name}/build
+       break
+done
+sed -i -e '/^phpdir/ s,/php/build,/%{name}/build,' $RPM_BUILD_ROOT%{_bindir}/phpize
 
 # for php-pecl-mailparse
 install -d $RPM_BUILD_ROOT%{_includedir}/php/ext/mbstring
@@ -2555,7 +2681,7 @@ sed -i -e "s|^libdir=.*|libdir='%{_libdir}'|" $RPM_BUILD_ROOT%{_libdir}/libphp_c
 sed -i -e "/dependency_libs/ s,/[^ ]*/libs/libphp_common.la,%{_libdir}/libphp_common.la," $RPM_BUILD_ROOT%{_libdir}/libphp5.la
 %endif
 # better solution?
-sed -i -e 's|libphp_common.la|$(libdir)/libphp_common.la|' $RPM_BUILD_ROOT%{_libdir}/php/build/acinclude.m4
+sed -i -e 's|libphp_common.la|$(libdir)/libphp_common.la|' $RPM_BUILD_ROOT%{_libdir}/%{name}/build/acinclude.m4
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -2625,6 +2751,35 @@ fi
 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
 [ ! -f /etc/httpd/conf.d/??_mod_php.conf ] || %service -q httpd restart
 
+%triggerpostun common -- php-common < 4:5.3.28-7
+# migrate configs /etc/php/conf.d -> /etc/phpXY/conf.d/
+# do config migration in php-common trigger, as the trigger is ran after all packages are upgraded
+# this way we can stick to one trigger, instead of attaching one for each (sub)package!
+for f in /etc/php/*.ini.rpmsave /etc/php/*.d/*.ini.rpmsave; do
+       test -f "$f" || continue
+       bn=${f#/etc/php/}
+       dn=${bn%/*}
+       fn=${bn#*/}
+       test "$dn" = "$fn" && dn=
+       fn=${fn%.rpmsave}
+       nf=%{_sysconfdir}/$dn/$fn
+       test -f "$nf" || continue
+       cp -vf $nf{,.rpmnew}
+       mv -vf $f $nf
+       %{__sed} -i -e '
+               s#%{_libdir}/php#%{_libdir}/%{name}#
+               s#/etc/php#%{_sysconfdir}#
+       ' $nf
+done
+
+%triggerpostun common -- %{name}-common < 4:5.3.29-7, php-common < 4:5.3.29-7
+# switch to browscap package if the ini file has original value
+%{__sed} -i -e 's#%{_sysconfdir}/browscap.ini#/usr/share/browscap/php_browscap.ini#' %{_sysconfdir}/php.ini
+# disable browscap, if optional package not present
+if [ ! -e /usr/share/browscap/php_browscap.ini ]; then
+       %{__sed} -i -e 's#^browscap = /usr/share/browscap/php_browscap.ini#;&#' %{_sysconfdir}/php.ini
+fi
+
 # common macros called at extension post/postun scriptlet
 %define        extension_scripts() \
 %post %1 \
@@ -2788,7 +2943,6 @@ fi
 %dir %{_sysconfdir}
 %dir %{_sysconfdir}/conf.d
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/php.ini
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/browscap.ini
 %attr(755,root,root) %{_libdir}/libphp_common-*.so
 %dir %{php_extensiondir}
 
@@ -2802,7 +2956,7 @@ fi
 %attr(755,root,root) %{_libdir}/libphp_common.so
 %{_libdir}/libphp_common.la
 %{_includedir}/php
-%{_libdir}/php/build
+%{_libdir}/%{name}/build
 %{_mandir}/man1/php-config.1*
 %{_mandir}/man1/phpize.1*
 %if %{with embed}
@@ -2996,7 +3150,7 @@ fi
 %attr(755,root,root) %{php_extensiondir}/mysqlnd.so
 %endif
 
-%if %{with oci8}
+%if %{with oci}
 %files oci8
 %defattr(644,root,root,755)
 %doc ext/oci8/{CREDITS,README}
@@ -3062,7 +3216,7 @@ fi
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/pdo_mysql.ini
 %attr(755,root,root) %{php_extensiondir}/pdo_mysql.so
 
-%if %{with oci8}
+%if %{with oci}
 %files pdo-oci
 %defattr(644,root,root,755)
 %doc ext/pdo_oci/CREDITS
This page took 1.946706 seconds and 4 git commands to generate.