From 7bfbad9a5da1fc8770fcc5ff23635bfb297fa8dd Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 10 Mar 2014 12:49:03 +0100 Subject: php-pecl-igbinary: merge scl stuff --- php-pecl-igbinary.spec | 47 ++++++++++++++++++++++++++++++++++------------- 1 file changed, 34 insertions(+), 13 deletions(-) diff --git a/php-pecl-igbinary.spec b/php-pecl-igbinary.spec index 92c57ff..7fd7fa7 100644 --- a/php-pecl-igbinary.spec +++ b/php-pecl-igbinary.spec @@ -6,15 +6,19 @@ # # Please, preserve the changelog entries # -%{!?__pecl: %{expand: %%global __pecl %{_bindir}/pecl}} +%{?scl: %scl_package php-pecl-igbinary} +%{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d} +%{!?__pecl: %global __pecl %{_bindir}/pecl} +%{!?__php: %global __php %{_bindir}/php} %global extname igbinary +%global with_zts 0%{?__ztsphp:1} %global commit c35d48f3d14794373b2ef89a6d79020bb7418d7f %global short %(c=%{commit}; echo ${c:0:7}) %global prever -dev Summary: Replacement for the standard PHP serializer -Name: php-pecl-igbinary +Name: %{?scl_prefix}php-pecl-igbinary Version: 1.1.2 %if 0%{?short:1} Release: 0.8.git%{short}%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} @@ -34,33 +38,37 @@ URL: http://pecl.php.net/package/igbinary # https://github.com/igbinary/igbinary/pull/24 Patch0: igbinary-apcu.patch -BuildRoot: %{_tmppath}/%{name}-%{version}-root-%(%{__id_u} -n) -BuildRequires: php-pear -BuildRequires: php-devel >= 5.2.0 +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildRequires: %{?scl_prefix}php-pear +BuildRequires: %{?scl_prefix}php-devel >= 5.2.0 # php-pecl-apcu-devel provides php-pecl-apc-devel -BuildRequires: php-pecl-apc-devel >= 3.1.7 +BuildRequires: %{?scl_prefix}php-pecl-apc-devel >= 3.1.7 Requires(post): %{__pecl} Requires(postun): %{__pecl} -Requires: php(zend-abi) = %{php_zend_api} -Requires: php(api) = %{php_core_api} +Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} +Requires: %{?scl_prefix}php(api) = %{php_core_api} -Obsoletes: php-%{extname} <= 1.1.1 -Provides: php-%{extname} = %{version} -Provides: php-%{extname}%{?_isa} = %{version} -Provides: php-pecl(%{extname}) = %{version} -Provides: php-pecl(%{extname})%{?_isa} = %{version} +Obsoletes: %{?scl_prefix}php-%{extname} <= 1.1.1 +Provides: %{?scl_prefix}php-%{extname} = %{version} +Provides: %{?scl_prefix}php-%{extname}%{?_isa} = %{version} +Provides: %{?scl_prefix}php-pecl(%{extname}) = %{version} +Provides: %{?scl_prefix}php-pecl(%{extname})%{?_isa} = %{version} +%if 0%{!?scl:1} # Other third party repo stuff +%if "%{php_version}" > "5.4" Obsoletes: php53-pecl-%{extname} Obsoletes: php53u-pecl-%{extname} Obsoletes: php54-pecl-%{extname} +%endif %if "%{php_version}" > "5.5" Obsoletes: php55u-pecl-%{extname} %endif %if "%{php_version}" > "5.6" Obsoletes: php56u-pecl-%{extname} %endif +%endif %if 0%{?fedora} < 20 # Filter shared private @@ -117,7 +125,9 @@ if test "x${extver}" != "x%{version}%{?prever}"; then fi cd .. +%if %{with_zts} cp -r %{extname}-%{version} %{extname}-%{version}-zts +%endif cat <