diff options
Diffstat (limited to 'php-pecl-pthreads.spec')
-rw-r--r-- | php-pecl-pthreads.spec | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/php-pecl-pthreads.spec b/php-pecl-pthreads.spec index bf0fdd8..e246901 100644 --- a/php-pecl-pthreads.spec +++ b/php-pecl-pthreads.spec @@ -21,7 +21,7 @@ Summary: Threading API Name: %{?scl_prefix}php-pecl-%{pecl_name} Version: 2.0.10 -Release: 1%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} +Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP Group: Development/Languages URL: http://pecl.php.net/package/%{pecl_name} @@ -31,8 +31,6 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: %{?scl_prefix}php-zts-devel > 5.3 BuildRequires: %{?scl_prefix}php-pear -Requires(post): %{__pecl} -Requires(postun): %{__pecl} Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} %{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} @@ -66,13 +64,13 @@ Obsoletes: php56w-pecl-%{pecl_name} <= %{version} %description -A compatible Threading API for PHP5.3+ +A compatible Threading API for PHP. Documentation: http://php.net/pthreads This extension is only available for PHP in ZTS mode. -Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection}. +Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{?scl_vendor}%{!?scl_vendor:rh})}. %prep @@ -126,12 +124,20 @@ do sed -e 's/\r//' -i $i done -%post -%{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : +# when pear installed alone, after us +%triggerin -- %{?scl_prefix}php-pear +if [ -x %{__pecl} ] ; then + %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : +fi +# posttrans as pear can be installed after us +%posttrans +if [ -x %{__pecl} ] ; then + %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : +fi %postun -if [ $1 -eq 0 ] ; then +if [ $1 -eq 0 -a -x %{__pecl} ] ; then %{pecl_uninstall} %{pecl_name} >/dev/null || : fi |