summaryrefslogtreecommitdiffstats
path: root/php-pecl-pcsc.spec
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2015-01-23 09:12:15 +0100
committerRemi Collet <fedora@famillecollet.com>2015-01-23 09:12:15 +0100
commite954c6086789dee07d6d58d7a20811645282b47c (patch)
tree8324a42e8f77c8e2926ed4fb1476bfede74e4c87 /php-pecl-pcsc.spec
parentde3c8db0e5d797306363f7365704a9098f7f3637 (diff)
php-pecl-pcsc: 0.3.1 (alpha)
Diffstat (limited to 'php-pecl-pcsc.spec')
-rw-r--r--php-pecl-pcsc.spec50
1 files changed, 28 insertions, 22 deletions
diff --git a/php-pecl-pcsc.spec b/php-pecl-pcsc.spec
index 60cc2f0..9ff7317 100644
--- a/php-pecl-pcsc.spec
+++ b/php-pecl-pcsc.spec
@@ -21,19 +21,13 @@
Summary: An extension for PHP using the winscard PC/SC API
Name: %{?scl_prefix}php-pecl-%{pecl_name}
-Version: 0.3
-Release: 2%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}.1
+Version: 0.3.1
+Release: 1%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}
License: BSD
Group: Development/Languages
URL: http://pecl.php.net/package/%{pecl_name}
Source0: http://pecl.php.net/get/%{pecl_name}-%{version}.tgz
-# http://svn.php.net/viewvc?view=revision&revision=333471
-# http://svn.php.net/viewvc?view=revision&revision=333472
-# http://svn.php.net/viewvc?view=revision&revision=333473
-# http://svn.php.net/viewvc?view=revision&revision=333474
-Patch0: %{pecl_name}-build.patch
-
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: pcsc-lite-devel
BuildRequires: %{?scl_prefix}php-devel > 5.3
@@ -52,17 +46,17 @@ Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version}
%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1}
# Other third party repo stuff
-Obsoletes: php53-pecl-%{pecl_name}
-Obsoletes: php53u-pecl-%{pecl_name}
-Obsoletes: php54-pecl-%{pecl_name}
-Obsoletes: php54w-pecl-%{pecl_name}
+Obsoletes: php53-pecl-%{pecl_name} <= %{version}
+Obsoletes: php53u-pecl-%{pecl_name} <= %{version}
+Obsoletes: php54-pecl-%{pecl_name} <= %{version}
+Obsoletes: php54w-pecl-%{pecl_name} <= %{version}
%if "%{php_version}" > "5.5"
-Obsoletes: php55u-pecl-%{pecl_name}
-Obsoletes: php55w-pecl-%{pecl_name}
+Obsoletes: php55u-pecl-%{pecl_name} <= %{version}
+Obsoletes: php55w-pecl-%{pecl_name} <= %{version}
%endif
%if "%{php_version}" > "5.6"
-Obsoletes: php56u-pecl-%{pecl_name}
-Obsoletes: php56w-pecl-%{pecl_name}
+Obsoletes: php56u-pecl-%{pecl_name} <= %{version}
+Obsoletes: php56w-pecl-%{pecl_name} <= %{version}
%endif
%endif
@@ -78,6 +72,8 @@ This is an extension for using PC/SC based smart cards with PHP.
It is a wrapper to the wonderful and free project PCSC-Lite which is the
middleware to access a smart card using SCard API (PC/SC).
+Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection}.
+
%package devel
Summary: %{name} developer files (header)
@@ -94,8 +90,6 @@ These are the files needed to compile programs using %{name}.
mv %{pecl_name}-%{version} NTS
cd NTS
-%patch0 -p3 -b .build
-
# Sanity check, really often broken
extver=$(sed -n '/#define PHP_PCSC_VERSION/{s/.* "//;s/".*$//;p}' php_pcsc.h)
if test "x${extver}" != "x%{version}"; then
@@ -153,18 +147,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
@@ -212,6 +214,10 @@ rm -rf %{buildroot}
%changelog
+* Fri Jan 23 2015 Remi Collet <remi@fedoraproject.org> - 0.3.1-1
+- Update to 0.3.1 (alpha)
+- drop runtime dependency on pear, new scriptlets
+
* Wed Dec 24 2014 Remi Collet <remi@fedoraproject.org> - 0.3-2.1
- Fedora 21 SCL mass rebuild