diff options
author | Remi Collet <fedora@famillecollet.com> | 2016-03-08 15:17:07 +0100 |
---|---|---|
committer | Remi Collet <fedora@famillecollet.com> | 2016-03-08 15:17:07 +0100 |
commit | e274cf759f02697a7ed7109356b1639e52fe9bc5 (patch) | |
tree | 71e9b1f307bf2583a0758cd27575352978b3cb2f | |
parent | 66f5e831b1e3a0a57c6b50ad42c7653626abf850 (diff) |
php-pecl-quickhash: F24
-rw-r--r-- | php-pecl-quickhash.spec | 41 |
1 files changed, 29 insertions, 12 deletions
diff --git a/php-pecl-quickhash.spec b/php-pecl-quickhash.spec index c6d13b5..c59c678 100644 --- a/php-pecl-quickhash.spec +++ b/php-pecl-quickhash.spec @@ -7,9 +7,6 @@ # Please, preserve the changelog entries # %{?scl: %scl_package php-pecl-ssdeep} -%{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d} -%{!?__pecl: %global __pecl %{_bindir}/pecl} -%{!?__php: %global __php %{_bindir}/php} %global pecl_name quickhash %global with_zts 0%{?__ztsphp:1} @@ -22,7 +19,7 @@ Summary: Set of specific strongly-typed classes for sets and hashing Name: %{?scl_prefix}php-pecl-%{pecl_name} Version: 1.0.0 -Release: 6%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} +Release: 7%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} License: PHP Group: Development/Languages URL: http://pecl.php.net/package/%{pecl_name} @@ -36,16 +33,16 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: %{?scl_prefix}php-devel 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}} -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_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} +Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release} +Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release} %if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1} # Other third party repo stuff @@ -78,11 +75,15 @@ the sets and hashes. Documentation: http://php.net/quickhash +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 %setup -q -c mv %{pecl_name}-%{version} NTS +%{?_licensedir:sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml} + cd NTS %patch0 -p1 %patch1 -p1 @@ -150,14 +151,24 @@ do install -Dpm 644 NTS/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done -%post -%{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : +%if 0%{?fedora} < 24 +# 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 +%endif %check @@ -197,6 +208,7 @@ rm -rf %{buildroot} %files %defattr(-,root,root,-) +%{?_licensedir:%license NTS/LICENSE} %doc %{pecl_docdir}/%{pecl_name} %{pecl_xmldir}/%{name}.xml @@ -210,6 +222,11 @@ rm -rf %{buildroot} %changelog +* Tue Mar 8 2016 Remi Collet <remi@fedoraproject.org> - 1.0.0-7 +- adapt for F24 +- drop runtime dependency on pear, new scriptlets +- fix license management + * Sat Feb 28 2015 Remi Collet <remi@fedoraproject.org> - 1.0.0-6 - add patch for GCC 5 build - open https://github.com/derickr/quickhash/pull/5 |