X-Git-Url: http://git.pld-linux.org/?p=packages%2Fopensc.git;a=blobdiff_plain;f=opensc.spec;h=b12a0ff890dae74e3446c297949b00a11a4f9fef;hp=a0f3bcbf7f0132398b2f94e382124e0052132ee0;hb=c9f4880d0ed484079305b6a5d0670dcf2a569d0d;hpb=fcac1d3391d00442a3c0c5bca3e379990c7a8e98 diff --git a/opensc.spec b/opensc.spec index a0f3bcb..b12a0ff 100644 --- a/opensc.spec +++ b/opensc.spec @@ -1,37 +1,41 @@ Summary: OpenSC library - for accessing SmartCard devices using PC/SC Lite Summary(pl.UTF-8): Biblioteka OpenSC - do korzystania z kart procesorowych przy użyciu PC/SC Lite Name: opensc -Version: 0.11.3 -Release: 1 +Version: 0.11.13 +Release: 2 Epoch: 0 License: LGPL v2.1+ Group: Applications Source0: http://www.opensc-project.org/files/opensc/%{name}-%{version}.tar.gz -# Source0-md5: 10897652e1f8d08d3c953982a4237f2e -Patch0: %{name}-explorer-debug.patch +# Source0-md5: 98fa151e947941f9c3f27420fdf47c11 +Source1: %{name}-initramfs-hook +Source2: %{name}-initramfs-local-bottom +Source3: %{name}-initramfs-local-top +Source4: %{name}-initramfs-README +Patch0: %{name}-libassuan-2.patch +Patch1: %{name}-pcsc.patch URL: http://www.opensc-project.org/ -BuildRequires: autoconf >= 2.52 -BuildRequires: automake -BuildRequires: libassuan-devel >= 1:0.6.0 +BuildRequires: autoconf >= 2.60 +BuildRequires: automake >= 1:1.10 +BuildRequires: libassuan-devel >= 1:2.0.0 BuildRequires: libltdl-devel BuildRequires: libtool >= 1:1.4.2-9 +BuildRequires: libxslt-progs BuildRequires: openct-devel BuildRequires: openldap-devel >= 2.4.6 BuildRequires: openssl-devel >= 0.9.7d -BuildRequires: pcsc-lite-devel +BuildRequires: pcsc-lite-devel >= 1.6.0 BuildRequires: pkgconfig >= 1:0.9.0 BuildRequires: readline-devel -BuildRequires: rpmbuild(macros) >= 1.236 +BuildRequires: rpmbuild(macros) >= 1.364 +BuildRequires: xorg-lib-libXt-devel +BuildRequires: zlib-devel +Requires: pcsc-lite-libs >= 1.6.0 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) # datadir is used for config files and (editable) profiles %define _datadir /etc %define _sysconfdir /etc/opensc -%define _plugindir %{_libdir}/browser-plugins - -# TODO: galeon and skipstone. -# use macro, otherwise extra LF inserted along with the ifarch -%define browsers mozilla, mozilla-firefox, konqueror, opera, seamonkey %description libopensc is a library for accessing SmartCard devices using PC/SC @@ -60,7 +64,7 @@ Requires: %{name} = %{epoch}:%{version}-%{release} Requires: libltdl-devel Requires: openct-devel Requires: openssl-devel -Requires: pcsc-lite-devel +Requires: pcsc-lite-devel >= 1.6.0 %description devel OpenSC development files. @@ -85,8 +89,9 @@ Summary: OpenSC Signer plugin for Mozilla Summary(pl.UTF-8): Wtyczka OpenSC Signer dla Mozilli Group: X11/Applications Requires: %{name} = %{epoch}:%{version}-%{release} +Requires: browser-plugins >= 2.0 Requires: browser-plugins(%{_target_base_arch}) -Requires: pinentry-gtk +Requires: pinentry >= 0.7.5-2 Provides: mozilla-plugin-opensc Obsoletes: mozilla-plugin-opensc @@ -100,37 +105,61 @@ Wtyczka OpenSC Signer dla przeglądarek. Obsługiwane przeglądarki: %{browsers}. +%package initramfs +Summary: OpenSC support scripts for initramfs-tools +Summary(pl.UTF-8): Skrypty dla initramfs-tools ze wsparciem dla OpenSC +Group: Base +Requires: %{name} = %{version}-%{release} +Requires: initramfs-tools + +%description initramfs +OpenSC support scripts for initramfs-tools. + +%description initramfs -l pl.UTF-8 +Skrypty dla initramfs-tools ze wsparciem dla OpenSC. + %prep %setup -q %patch0 -p1 +%patch1 -p1 + +install %{SOURCE4} README.initramfs %build -touch config.rpath %{__libtoolize} -%{__aclocal} -I aclocal +%{__aclocal} -I m4 %{__autoconf} %{__autoheader} %{__automake} %configure \ - --with-pin-entry=/usr/bin/pinentry-gtk \ - --with-plugin-dir="%{_plugindir}" + --enable-openct \ + --enable-nsplugin \ + --enable-pcsc \ + --with-pcsc-provider=%{_libdir}/libpcsclite.so.1 \ + --with-pinentry=/usr/bin/pinentry \ + --with-plugindir=%{_browserpluginsdir} %{__make} %install rm -rf $RPM_BUILD_ROOT -install -d $RPM_BUILD_ROOT%{_plugindir} +install -d $RPM_BUILD_ROOT%{_browserpluginsdir} \ + $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/{hooks,scripts/local-{bottom,top}} %{__make} install \ DESTDIR=$RPM_BUILD_ROOT # just install instead of symlinking -rm -f $RPM_BUILD_ROOT%{_plugindir}/opensc-signer.so -mv -f $RPM_BUILD_ROOT%{_libdir}/opensc-signer.so $RPM_BUILD_ROOT%{_plugindir} +%{__rm} $RPM_BUILD_ROOT%{_browserpluginsdir}/opensc-signer.so +mv -f $RPM_BUILD_ROOT%{_libdir}/opensc-signer.so $RPM_BUILD_ROOT%{_browserpluginsdir} # default config install etc/opensc.conf $RPM_BUILD_ROOT%{_sysconfdir} +install %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/hooks/opensc +install %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/scripts/local-bottom/opensc +install %{SOURCE3} $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/scripts/local-top/opensc + # useless (dlopened by *.so) rm -f $RPM_BUILD_ROOT%{_libdir}/{onepin-opensc,opensc,pkcs11}-*.{a,la} \ $RPM_BUILD_ROOT%{_libdir}/opensc/*.{a,la} @@ -141,45 +170,19 @@ rm -rf $RPM_BUILD_ROOT %post -p /sbin/ldconfig %postun -p /sbin/ldconfig -%triggerin -n browser-plugin-opensc -- mozilla-firefox -%nsplugin_install -d %{_libdir}/mozilla-firefox/plugins opensc-signer.so - -%triggerun -n browser-plugin-opensc -- mozilla-firefox -%nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins opensc-signer.so - -%triggerin -n browser-plugin-opensc -- mozilla -%nsplugin_install -d %{_libdir}/mozilla/plugins opensc-signer.so - -%triggerun -n browser-plugin-opensc -- mozilla -%nsplugin_uninstall -d %{_libdir}/mozilla/plugins opensc-signer.so +%post -n browser-plugin-opensc +%update_browser_plugins -%triggerin -n browser-plugin-opensc -- opera -%nsplugin_install -d %{_libdir}/opera/plugins opensc-signer.so - -%triggerun -n browser-plugin-opensc -- opera -%nsplugin_uninstall -d %{_libdir}/opera/plugins opensc-signer.so - -%triggerin -n browser-plugin-opensc -- konqueror -%nsplugin_install -d %{_libdir}/kde3/plugins/konqueror opensc-signer.so - -%triggerun -n browser-plugin-opensc -- konqueror -%nsplugin_uninstall -d %{_libdir}/kde3/plugins/konqueror opensc-signer.so - -%triggerin -n browser-plugin-opensc -- seamonkey -%nsplugin_install -d %{_libdir}/seamonkey/plugins opensc-signer.so - -%triggerun -n browser-plugin-opensc -- seamonkey -%nsplugin_uninstall -d %{_libdir}/seamonkey/plugins opensc-signer.so - -# as rpm removes the old obsoleted package files after the triggers -# are ran, add another trigger to make the links there. -%triggerpostun -n browser-plugin-opensc -- mozilla-plugin-opensc -%nsplugin_install -f -d %{_libdir}/mozilla/plugins opensc-signer.so +%postun -n browser-plugin-opensc +if [ "$1" = "0" ]; then + %update_browser_plugins +fi %files %defattr(644,root,root,755) -%doc NEWS README doc/ChangeLog doc/{*.{html,css},html/tools.html} +%doc NEWS README doc/nonpersistent/{ChangeLog,wiki.out} doc/html.out/tools.html %attr(755,root,root) %{_bindir}/cardos-info +%attr(755,root,root) %{_bindir}/cardos-tool %attr(755,root,root) %{_bindir}/cryptoflex-tool %attr(755,root,root) %{_bindir}/eidenv %attr(755,root,root) %{_bindir}/netkey-tool @@ -188,25 +191,38 @@ rm -rf $RPM_BUILD_ROOT %attr(755,root,root) %{_bindir}/piv-tool %attr(755,root,root) %{_bindir}/pkcs11-tool %attr(755,root,root) %{_bindir}/pkcs15-* -%attr(755,root,root) %{_libdir}/lib*.so.*.* +%attr(755,root,root) %{_bindir}/rutoken-tool +%attr(755,root,root) %{_bindir}/westcos-tool +%attr(755,root,root) %{_libdir}/libopensc.so.*.*.* +%attr(755,root,root) %ghost %{_libdir}/libopensc.so.2 +%attr(755,root,root) %{_libdir}/libpkcs15init.so.*.*.* +%attr(755,root,root) %ghost %{_libdir}/libpkcs15init.so.2 +%attr(755,root,root) %{_libdir}/libscconf.so.*.*.* +%attr(755,root,root) %ghost %{_libdir}/libscconf.so.2 +# PKCS11 modules %attr(755,root,root) %{_libdir}/onepin-opensc-pkcs11.so %attr(755,root,root) %{_libdir}/opensc-pkcs11.so %attr(755,root,root) %{_libdir}/pkcs11-spy.so +%dir %{_libdir}/pkcs11 +%attr(755,root,root) %{_libdir}/pkcs11/onepin-opensc-pkcs11.so +%attr(755,root,root) %{_libdir}/pkcs11/opensc-pkcs11.so +%attr(755,root,root) %{_libdir}/pkcs11/pkcs11-spy.so %dir %{_datadir}/opensc -%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.conf +%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/opensc.conf %config(noreplace) %verify(not md5 mtime size) %{_datadir}/opensc/*.profile -%{_mandir}/man1/cardos-info.1* +%{_mandir}/man1/cardos-tool.1* %{_mandir}/man1/cryptoflex-tool.1* %{_mandir}/man1/netkey-tool.1* %{_mandir}/man1/opensc-explorer.1* %{_mandir}/man1/opensc-tool.1* %{_mandir}/man1/pkcs11-tool.1* %{_mandir}/man1/pkcs15-*.1* -%{_mandir}/man[57]/* +%{_mandir}/man1/westcos-tool.1* +%{_mandir}/man5/pkcs15-profile.5* %files devel %defattr(644,root,root,755) -%doc doc/html/api.html +%doc doc/html.out/api.html %attr(755,root,root) %{_bindir}/opensc-config %attr(755,root,root) %{_libdir}/libopensc.so %attr(755,root,root) %{_libdir}/libpkcs15init.so @@ -215,9 +231,11 @@ rm -rf $RPM_BUILD_ROOT %{_libdir}/libpkcs15init.la %{_libdir}/libscconf.la %{_includedir}/opensc -%{_pkgconfigdir}/*.pc +%{_pkgconfigdir}/libopensc.pc +%{_pkgconfigdir}/libpkcs15init.pc +%{_pkgconfigdir}/libscconf.pc %{_mandir}/man1/opensc-config.1* -%{_mandir}/man3/* +%{_mandir}/man3/sc_*.3* %files static %defattr(644,root,root,755) @@ -227,4 +245,11 @@ rm -rf $RPM_BUILD_ROOT %files -n browser-plugin-opensc %defattr(644,root,root,755) -%attr(755,root,root) %{_plugindir}/opensc-signer.so +%attr(755,root,root) %{_browserpluginsdir}/opensc-signer.so + +%files initramfs +%defattr(644,root,root,755) +%doc README.initramfs +%attr(755,root,root) %{_datadir}/initramfs-tools/hooks/opensc +%attr(755,root,root) %{_datadir}/initramfs-tools/scripts/local-top/opensc +%attr(755,root,root) %{_datadir}/initramfs-tools/scripts/local-bottom/opensc