summaryrefslogtreecommitdiffstats
path: root/php-pecl-raphf.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-pecl-raphf.spec')
-rw-r--r--php-pecl-raphf.spec44
1 files changed, 25 insertions, 19 deletions
diff --git a/php-pecl-raphf.spec b/php-pecl-raphf.spec
index a693737..6a0d172 100644
--- a/php-pecl-raphf.spec
+++ b/php-pecl-raphf.spec
@@ -6,6 +6,7 @@
#
# Please, preserve the changelog entries
#
+%{?scl: %scl_package php-pecl-raphf}
%{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d}
%{!?php_incldir: %global php_incldir %{_includedir}/php}
%{!?__pecl: %global __pecl %{_bindir}/pecl}
@@ -14,11 +15,11 @@
%global with_zts 0%{?__ztsphp:1}
%global pecl_name raphf
# tests disabled because of circular dependency on pecl/http
-# tests requires not yet release pecl/http 2.0.0beta6
+# tests requires pecl/http 2.0.0
%global with_tests %{?_with_tests:1}%{!?_with_tests:0}
Summary: Resource and persistent handles factory
-Name: php-pecl-%{pecl_name}
+Name: %{?scl_prefix}php-pecl-%{pecl_name}
Version: 1.0.4
Release: 1%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}
License: BSD
@@ -27,30 +28,32 @@ URL: http://pecl.php.net/package/%{pecl_name}
Source0: http://pecl.php.net/get/%{pecl_name}-%{version}.tgz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-BuildRequires: php-devel > 5.3
-BuildRequires: php-pear
+BuildRequires: %{?scl_prefix}php-devel > 5.3
+BuildRequires: %{?scl_prefix}php-pear
%if %{with_tests}
-BuildRequires: php-pecl-http
+BuildRequires: %{?scl_prefix}php-pecl-http >= 2.0.0
%endif
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}
-Provides: php-%{pecl_name} = %{version}
-Provides: php-%{pecl_name}%{?_isa} = %{version}
-Provides: php-pecl(%{pecl_name}) = %{version}
-Provides: php-pecl(%{pecl_name})%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-%{pecl_name} = %{version}
+Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-pecl(%{pecl_name}) = %{version}
+Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version}
+%if 0%{!?scl:1}
# Other third party repo stuff
%if "%{php_version}" > "5.4"
-Obsoletes: php53-pecl-raphf
-Obsoletes: php53u-pecl-raphf
-Obsoletes: php54-pecl-raphf
+Obsoletes: php53-pecl-%{pecl_name}
+Obsoletes: php53u-pecl-%{pecl_name}
+Obsoletes: php54-pecl-%{pecl_name}
%endif
%if "%{php_version}" > "5.5"
-Obsoletes: php55u-pecl-raphf
+Obsoletes: php55u-pecl-%{pecl_name}
+%endif
%endif
%if 0%{?fedora} < 20
@@ -69,7 +72,7 @@ factory API.
Summary: %{name} developer files (header)
Group: Development/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
-Requires: php-devel%{?_isa}
+Requires: %{?scl_prefix}php-devel%{?_isa}
%description devel
These are the files needed to compile programs using %{name}.
@@ -160,7 +163,7 @@ fi
%check
cd NTS
: Minimal load test for NTS extension
-php --no-php-ini \
+%{__php} --no-php-ini \
--define extension=modules/%{pecl_name}.so \
--modules | grep %{pecl_name}
@@ -172,11 +175,11 @@ for mod in json hash iconv propro; do
done
: Upstream test suite for NTS extension
-TEST_PHP_EXECUTABLE=%{_bindir}/php \
+TEST_PHP_EXECUTABLE=%{__php} \
TEST_PHP_ARGS="-n $modules -d extension=$PWD/modules/%{pecl_name}.so -d extension=http.so" \
NO_INTERACTION=1 \
REPORT_EXIT_STATUS=1 \
-%{_bindir}/php -n run-tests.php
+%{__php} -n run-tests.php
%endif
%if %{with_zts}
@@ -224,6 +227,9 @@ rm -rf %{buildroot}
%changelog
+* Fri Nov 29 2013 Remi Collet <rcollet@redhat.com> - 1.0.4-1
+- adapt for SCL
+
* Tue Nov 26 2013 Remi Collet <remi@fedoraproject.org> - 1.0.4-1
- Update to 1.0.4 (stable)