summaryrefslogtreecommitdiffstats
path: root/php-pecl-ircclient.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-pecl-ircclient.spec')
-rw-r--r--php-pecl-ircclient.spec27
1 files changed, 19 insertions, 8 deletions
diff --git a/php-pecl-ircclient.spec b/php-pecl-ircclient.spec
index 639bff9..78c960b 100644
--- a/php-pecl-ircclient.spec
+++ b/php-pecl-ircclient.spec
@@ -1,4 +1,4 @@
-# spec file for php-pecl-ircclient
+# remirepo spec file for php-pecl-ircclient
#
# Copyright (c) 2014-2015 Remi Collet
# License: CC-BY-SA
@@ -22,7 +22,7 @@
Summary: IRC Client
Name: %{?scl_prefix}php-pecl-%{pecl_name}
Version: 0.3.0
-Release: 3%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}.1
+Release: 4%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}
License: BSD
Group: Development/Languages
URL: http://pecl.php.net/package/%{pecl_name}
@@ -37,8 +37,6 @@ BuildRequires: libircclient-devel
BuildRequires: %{?scl_prefix}php-devel > 5.2
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}}
@@ -130,18 +128,26 @@ make -C ZTS \
install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name}
%endif
-# Test & Documentation
+# Documentation
for i in $(grep 'role="doc"' package.xml | sed -e 's/^.*name="//;s/".*$//')
do install -Dpm 644 NTS/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$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
@@ -170,6 +176,7 @@ rm -rf %{buildroot}
%defattr(-,root,root,-)
%doc %{pecl_docdir}/%{pecl_name}
%{pecl_xmldir}/%{name}.xml
+
%config(noreplace) %{php_inidir}/%{ini_name}
%{php_extdir}/%{pecl_name}.so
@@ -180,6 +187,10 @@ rm -rf %{buildroot}
%changelog
+* Tue Jun 2 2015 Remi Collet <remi@fedoraproject.org> - 0.3.0-4
+- drop runtime dependency on pear, new scriptlets
+- rebuild for libircclient in EPEL
+
* Wed Dec 24 2014 Remi Collet <remi@fedoraproject.org> - 0.3.0-3.1
- Fedora 21 SCL mass rebuild