]> git.pld-linux.org Git - packages/pcsc-lite.git/blobdiff - pcsc-lite.spec
- updated to 1.3.3
[packages/pcsc-lite.git] / pcsc-lite.spec
index b07bff4d41e164e505a069607d2fa0c52d72f071..aacd48f7096a946f3404b3f9d332f77fb3171840 100644 (file)
@@ -1,25 +1,33 @@
 Summary:       Muscle PCSC Framework for Linux
 Summary(pl):   ¦rodowisko PCSC dla Linuksa
 Name:          pcsc-lite
-Version:       1.1.1
-Release:       2
+Version:       1.3.3
+Release:       1
 License:       BSD
 Group:         Daemons
-Source0:       http://linuxnet.com/middleware/file/%{name}-%{version}.tar.gz
+#Source0Download: http://alioth.debian.org/project/showfiles.php?group_id=30105
+Source0:       http://alioth.debian.org/frs/download.php/1869/%{name}-%{version}.tar.gz
+# Source0-md5: 851b090aa0efedd0196f6afd9c0c61bb
 Source1:       %{name}-pcscd.init
 Source2:       %{name}-pcscd.sysconfig
 Patch0:                %{name}-fhs.patch
-Patch1:                %{name}-link.patch
-Patch2:                %{name}-amfix.patch
+Patch1:                %{name}-any.patch
 URL:           http://www.linuxnet.com/middle.html
-BuildRequires: autoconf
-BuildRequires: automake
+BuildRequires: autoconf >= 2.58
+BuildRequires: automake >= 1:1.8
 BuildRequires: flex
-BuildRequires: libtool
-PreReq:                rc-scripts
+BuildRequires: libtool >= 1.4.2-9
+BuildRequires: libusb-devel >= 0.1.7
+BuildRequires: pkgconfig
+BuildRequires: rpmbuild(macros) >= 1.268
 Requires(post,preun):  /sbin/chkconfig
+Requires(pre): fileutils
+Requires:      rc-scripts
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+%define                usbdropdir      /usr/%{_lib}/pcsc/drivers
+%define                muscledropdir   /usr/%{_lib}/pcsc/services
+
 %description
 pcscd is the daemon program for PC/SC Lite. It is a resource manager
 that coorinates communications with Smart Card readers and Smart Cards
@@ -50,8 +58,8 @@ Biblioteki PC/SC Lite.
 %package devel
 Summary:       PC/SC Lite development files
 Summary(pl):   Pliki dla programistów u¿ywaj±cych PC/SC Lite
-Group:         Development/Tools
-Requires:      %{name}-libs = %{version}
+Group:         Development/Libraries
+Requires:      %{name}-libs = %{version}-%{release}
 
 %description devel
 PC/SC Lite development files.
@@ -62,8 +70,8 @@ Pliki dla programist
 %package static
 Summary:       Static PC/SC Lite libraries
 Summary(pl):   Biblioteki statyczne PC/SC Lite
-Group:         Development/Tools
-Requires:      %{name}-devel = %{version}
+Group:         Development/Libraries
+Requires:      %{name}-devel = %{version}-%{release}
 
 %description static
 Static PC/SC Lite libraries.
@@ -75,47 +83,54 @@ Statyczne biblioteki PC/SC Lite.
 %setup -q
 %patch0 -p1
 %patch1 -p1
-%patch2 -p1
 
 %build
 %{__libtoolize}
-%{__aclocal} -I build
+%{__aclocal} -I m4
 %{__autoconf}
+%{__autoheader}
 %{__automake}
-%configure
+%configure \
+       --enable-muscledropdir=%{muscledropdir} \
+       --enable-runpid=/var/run/pcscd.pid \
+       --enable-usbdropdir=%{usbdropdir}
 
 %{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_libdir}/pcsc/{drivers,services} \
-       $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig}
+install -d $RPM_BUILD_ROOT{%{usbdropdir},%{muscledropdir}} \
+       $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig} \
+       $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
 
 %{__make} install \
        DESTDIR=$RPM_BUILD_ROOT
 
-# useful for drivers development
-install src/ifdhandler.h $RPM_BUILD_ROOT%{_includedir}
-
 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/pcscd
 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/pcscd
 
+install doc/example/*.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+
+:> $RPM_BUILD_ROOT%{_sysconfdir}/reader.conf
+rm -rf $RPM_BUILD_ROOT%{_prefix}/doc
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%pre
+# upgrade from pcsc-lite < 1.2.9-0.beta7
+if [ -f /etc/reader.conf -a ! -f /etc/reader.conf.d/reader.conf ]; then
+       install -d -m755 /etc/reader.conf.d
+       cp -af /etc/reader.conf /etc/reader.conf.d/reader.conf
+fi
+
 %post
 /sbin/chkconfig --add pcscd
-if [ -f /var/lock/subsys/pcscd ]; then
-       /etc/rc.d/init.d/pcscd restart >&2
-else
-       echo "Run \"/etc/rc.d/init.d/pcscd start\" to start pcscd daemon."
-fi
+%service pcscd restart "pcscd daemon"
 
 %preun
 if [ "$1" = "0" ]; then
-       if [ -f /var/lock/subsys/pcscd ]; then
-               /etc/rc.d/init.d/pcscd stop >&2
-       fi
+       %service pcscd stop
        /sbin/chkconfig --del pcscd
 fi
 
@@ -124,28 +139,33 @@ fi
 
 %files
 %defattr(644,root,root,755)
-%doc AUTHORS COPYING DRIVERS NEWS HELP README SECURITY doc/{README.DAEMON,*.pdf,pcscd.startup}
-%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/reader.conf
-%attr(754,root,root) /etc/rc.d/init.d/pcscd
-%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/pcscd
+%doc AUTHORS COPYING ChangeLog* DRIVERS HELP NEWS README SECURITY TODO doc/README.DAEMON
 %attr(755,root,root) %{_sbindir}/pcscd
-%attr(755,root,root) %{_bindir}/bundleTool
-%attr(755,root,root) %{_bindir}/formaticc
-%attr(755,root,root) %{_bindir}/installifd
+%attr(755,root,root) %{_sbindir}/update-reader.conf
 %{_libdir}/pcsc
-%{_mandir}/man1/bundleTool.1*
+%dir %{_sysconfdir}/reader.conf.d
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/reader.conf.d/reader.conf
+%ghost %{_sysconfdir}/reader.conf
+%attr(754,root,root) /etc/rc.d/init.d/pcscd
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/pcscd
+%{_mandir}/man1/formaticc.1*
+%{_mandir}/man5/reader.conf.5*
 %{_mandir}/man8/pcscd.8*
+%{_mandir}/man8/update-reader.conf.8*
 
 %files libs
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so.*.*
+%attr(755,root,root) %{_libdir}/libpcsclite.so.*.*.*
 
 %files devel
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so
-%{_libdir}/libpcsc*.la
-%{_includedir}/*.h
+%doc doc/*.pdf
+%attr(755,root,root) %{_libdir}/libpcsclite.so
+%{_libdir}/libpcsclite.la
+%{_includedir}/PCSC
+%{_pkgconfigdir}/libpcsclite.pc
+%{_examplesdir}/%{name}-%{version}
 
 %files static
 %defattr(644,root,root,755)
-%{_libdir}/lib*.a
+%{_libdir}/libpcsclite.a
This page took 0.062853 seconds and 4 git commands to generate.