diff --git a/SPECS/php71u-pecl-oauth.spec b/SPECS/php71u-pecl-oauth.spec index 30a0f73..7e87b57 100644 --- a/SPECS/php71u-pecl-oauth.spec +++ b/SPECS/php71u-pecl-oauth.spec @@ -8,7 +8,7 @@ Name: %{php}-pecl-%{pecl_name} Version: 2.0.2 -Release: 1.ius%{?dist} +Release: 2.ius%{?dist} Summary: PHP OAuth consumer extension Group: Development/Languages License: BSD @@ -16,16 +16,19 @@ URL: https://pecl.php.net/package/oauth Source0: https://pecl.php.net/get/%{pecl_name}-%{version}.tgz BuildRequires: %{php}-devel -BuildRequires: pecl >= 1.10.0 BuildRequires: libcurl-devel BuildRequires: pcre-devel +BuildRequires: pear1u +# explicitly require pear dependencies to avoid conflicts +BuildRequires: %{php}-cli +BuildRequires: %{php}-common +BuildRequires: %{php}-process +BuildRequires: %{php}-xml + Requires: php(zend-abi) = %{php_zend_api} Requires: php(api) = %{php_core_api} -Requires(post): pecl >= 1.10.0 -Requires(postun): pecl >= 1.10.0 - # provide the stock name Provides: php-pecl-%{pecl_name} = %{version} Provides: php-pecl-%{pecl_name}%{?_isa} = %{version} @@ -123,12 +126,20 @@ done %endif -%post -%{pecl_install} %{pecl_xmldir}/%{pecl_name}.xml >/dev/null || : +%triggerin -- pear1u +if [ -x %{__pecl} ]; then + %{pecl_install} %{pecl_xmldir}/%{pecl_name}.xml >/dev/null || : +fi + + +%posttrans +if [ -x %{__pecl} ]; then + %{pecl_install} %{pecl_xmldir}/%{pecl_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 @@ -148,6 +159,9 @@ fi %changelog +* Wed Jan 31 2018 Carl George - 2.0.2-2.ius +- Remove pear requirement and update scriptlets (adapted from remirepo) + * Wed May 31 2017 Ben Harper - 2.0.2-1.ius - Port from Fedora