ccid145-vl.spec 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. %define dropdir %(pkg-config libpcsclite --variable usbdropdir 2>/dev/null)
  2. %define libusb1_ver 1.0.9
  3. %define pcsc_lite_ver 1.8.3
  4. Name: ccid145
  5. Version: 1.4.5
  6. Release: 1%{?_dist_release}
  7. Summary: Generic USB CCID smart card reader driver
  8. Summary(ja): Generic USB CCID smart card reader driver
  9. Group: System Environment/Libraries
  10. License: LGPLv2+
  11. URL: http://pcsclite.alioth.debian.org/ccid.html
  12. Source0: http://alioth.debian.org/download.php/1563/ccid-%{version}.tar.bz2
  13. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
  14. BuildRequires: libusb1-devel >= %{libusb1_ver}
  15. BuildRequires: pcsc-lite-devel >= %{pcsc_lite_ver}
  16. Requires(post): initscripts
  17. Requires(postun): initscripts
  18. Requires: libusb1
  19. Requires: pcsc-lite
  20. Provides: pcsc-ifd-handler
  21. Conflicts: ccid
  22. # 390 does not have libusb or smartCards
  23. ExcludeArch: s390 s390x
  24. %description
  25. Generic USB CCID (Chip/Smart Card Interface Devices) driver.
  26. %prep
  27. %setup -q -n ccid-%{version}
  28. for f in ChangeLog README ; do
  29. iconv -f iso-8859-1 -t utf-8 $f > $f.utf8 ; mv $f.utf8 $f
  30. done
  31. %build
  32. %configure --disable-dependency-tracking --disable-static --enable-twinserial
  33. make %{?_smp_mflags}
  34. %install
  35. rm -rf $RPM_BUILD_ROOT
  36. make install DESTDIR=$RPM_BUILD_ROOT
  37. %{__mkdir_p} $RPM_BUILD_ROOT/%{_sysconfdir}/udev/rules.d
  38. %{__install} -m 644 src/92_pcscd_ccid.rules $RPM_BUILD_ROOT/%{_sysconfdir}/udev/rules.d/92-pcscd_ccid.rules
  39. %clean
  40. rm -rf $RPM_BUILD_ROOT
  41. %post
  42. [ -x %{_initrddir}/pcscd ] && %{_initrddir}/pcscd status >> /dev/null 2>&1 && %{_sbindir}/pcscd -H > /dev/null 2>&1
  43. exit 0
  44. %postun
  45. [ -x %{_initrddir}/pcscd ] && %{_initrddir}/pcscd status >> /dev/null 2>&1 && %{_sbindir}/pcscd -H > /dev/null 2>&1
  46. exit 0
  47. %files
  48. %defattr(-,root,root,-)
  49. %doc AUTHORS ChangeLog COPYING NEWS README SCARDGETATTRIB.txt
  50. %{dropdir}/ifd-ccid.bundle/
  51. %{dropdir}/serial/
  52. %config(noreplace) %{_sysconfdir}/reader.conf.d/libccidtwin
  53. %config %{_sysconfdir}/udev/rules.d/92-pcscd_ccid.rules
  54. %changelog
  55. * Tue Jun 26 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.4.5-1
  56. - initial build