]>
Commit | Line | Data |
---|---|---|
1cefa9cb | 1 | Summary: OpenSC library - for accessing SmartCard devices using PC/SC Lite |
ae88f326 | 2 | Summary(pl.UTF-8): Biblioteka OpenSC - do korzystania z kart procesorowych przy użyciu PC/SC Lite |
896b833c | 3 | Name: opensc |
c39ac2c0 | 4 | Version: 0.11.4 |
1c9cc728 | 5 | Release: 1 |
e0fb86be | 6 | Epoch: 0 |
18e38179 | 7 | License: LGPL v2.1+ |
1cefa9cb | 8 | Group: Applications |
9c0288b5 | 9 | Source0: http://www.opensc-project.org/files/opensc/%{name}-%{version}.tar.gz |
c39ac2c0 | 10 | # Source0-md5: 2031aa617be609d50d014d5d370bb8a2 |
9c0288b5 | 11 | URL: http://www.opensc-project.org/ |
74b89671 | 12 | BuildRequires: autoconf >= 2.52 |
1cefa9cb | 13 | BuildRequires: automake |
6200ae89 | 14 | BuildRequires: libassuan-devel >= 1:0.6.0 |
8d087e90 | 15 | BuildRequires: libltdl-devel |
1cefa9cb | 16 | BuildRequires: libtool >= 1:1.4.2-9 |
543fbe6c | 17 | BuildRequires: openct-devel |
fcac1d33 | 18 | BuildRequires: openldap-devel >= 2.4.6 |
72eaba4f | 19 | BuildRequires: openssl-devel >= 0.9.7d |
1cefa9cb | 20 | BuildRequires: pcsc-lite-devel |
34f2d3c1 | 21 | BuildRequires: pkgconfig >= 1:0.9.0 |
1cefa9cb | 22 | BuildRequires: readline-devel |
543fbe6c | 23 | BuildRequires: rpmbuild(macros) >= 1.236 |
896b833c | 24 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
25 | ||
1eb351c9 | 26 | # datadir is used for config files and (editable) profiles |
ac174bda JB |
27 | %define _datadir /etc |
28 | %define _sysconfdir /etc/opensc | |
543fbe6c ER |
29 | %define _plugindir %{_libdir}/browser-plugins |
30 | ||
31 | # TODO: galeon and skipstone. | |
32 | # use macro, otherwise extra LF inserted along with the ifarch | |
33 | %define browsers mozilla, mozilla-firefox, konqueror, opera, seamonkey | |
d6f32863 | 34 | |
896b833c | 35 | %description |
1cefa9cb JB |
36 | libopensc is a library for accessing SmartCard devices using PC/SC |
37 | Lite middleware package. It is also the core library of the OpenSC | |
38 | project. Basic functionality (e.g. SELECT FILE, READ BINARY) should | |
39 | work on any ISO 7816-4 compatible SmartCard. Encryption and decryption | |
40 | using private keys on the SmartCard is at the moment possible only | |
41 | with PKCS#15 compatible cards, such as the FINEID (Finnish Electronic | |
42 | IDentity) card manufactured by Setec. | |
896b833c | 43 | |
8623b75b | 44 | %description -l pl.UTF-8 |
1cefa9cb | 45 | libopensc to biblioteka do korzystania z kart procesorowych przy |
8623b75b JR |
46 | użyciu pakietu warstwy pośredniej PC/SC Lite. Jest to także podstawowa |
47 | biblioteka projektu OpenSC. Podstawowa funkcjonalność (np. SELECT | |
48 | FILE, READ BINARY) powinna działać także z dowolną kartą procesorową | |
49 | zgodną z ISO-7816-4. Szyfrowanie i odszyfrowywanie przy użyciu | |
50 | prywatnych kluczy na karcie na razie jest możliwe tylko przy użyciu | |
1cefa9cb JB |
51 | kart kompatybilnych z PKCS#16, takich jak FINEID (Finnish Electronic |
52 | IDentity) produkowanych przez Setec. | |
896b833c | 53 | |
54 | %package devel | |
1cefa9cb | 55 | Summary: OpenSC development files |
ae88f326 | 56 | Summary(pl.UTF-8): Pliki dla programistów używających OpenSC |
896b833c | 57 | Group: Development/Tools |
9f872d80 | 58 | Requires: %{name} = %{epoch}:%{version}-%{release} |
24aae781 | 59 | Requires: libltdl-devel |
9f872d80 JB |
60 | Requires: openct-devel |
61 | Requires: openssl-devel | |
62 | Requires: pcsc-lite-devel | |
896b833c | 63 | |
64 | %description devel | |
1cefa9cb | 65 | OpenSC development files. |
896b833c | 66 | |
8623b75b JR |
67 | %description devel -l pl.UTF-8 |
68 | Pliki dla programistów używających OpenSC. | |
896b833c | 69 | |
70 | %package static | |
1cefa9cb | 71 | Summary: Static OpenSC libraries |
ae88f326 | 72 | Summary(pl.UTF-8): Bibloteki statyczne OpenSC |
896b833c | 73 | Group: Development/Tools |
9f872d80 | 74 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
896b833c | 75 | |
76 | %description static | |
1cefa9cb | 77 | Static OpenSC libraries. |
896b833c | 78 | |
8623b75b | 79 | %description static -l pl.UTF-8 |
1cefa9cb JB |
80 | Statyczne biblioteki OpenSC. |
81 | ||
543fbe6c | 82 | %package -n browser-plugin-opensc |
d6f32863 | 83 | Summary: OpenSC Signer plugin for Mozilla |
ae88f326 | 84 | Summary(pl.UTF-8): Wtyczka OpenSC Signer dla Mozilli |
d6f32863 | 85 | Group: X11/Applications |
9f872d80 | 86 | Requires: %{name} = %{epoch}:%{version}-%{release} |
543fbe6c | 87 | Requires: browser-plugins(%{_target_base_arch}) |
d6f32863 | 88 | Requires: pinentry-gtk |
543fbe6c ER |
89 | Provides: mozilla-plugin-opensc |
90 | Obsoletes: mozilla-plugin-opensc | |
91 | ||
92 | %description -n browser-plugin-opensc | |
93 | OpenSC Signer browser plugin. | |
d6f32863 | 94 | |
543fbe6c | 95 | Supported browsers: %{browsers}. |
d6f32863 | 96 | |
8623b75b JR |
97 | %description -n browser-plugin-opensc -l pl.UTF-8 |
98 | Wtyczka OpenSC Signer dla przeglądarek. | |
543fbe6c | 99 | |
8623b75b | 100 | Obsługiwane przeglądarki: %{browsers}. |
d6f32863 | 101 | |
896b833c | 102 | %prep |
1cefa9cb | 103 | %setup -q |
896b833c | 104 | |
105 | %build | |
b9c1b601 | 106 | touch config.rpath |
1cefa9cb | 107 | %{__libtoolize} |
8d087e90 | 108 | %{__aclocal} -I aclocal |
1cefa9cb | 109 | %{__autoconf} |
ac174bda | 110 | %{__autoheader} |
1cefa9cb | 111 | %{__automake} |
d6f32863 JB |
112 | %configure \ |
113 | --with-pin-entry=/usr/bin/pinentry-gtk \ | |
543fbe6c | 114 | --with-plugin-dir="%{_plugindir}" |
896b833c | 115 | |
1cefa9cb | 116 | %{__make} |
896b833c | 117 | |
118 | %install | |
119 | rm -rf $RPM_BUILD_ROOT | |
543fbe6c | 120 | install -d $RPM_BUILD_ROOT%{_plugindir} |
1cefa9cb | 121 | |
61f848e8 JB |
122 | %{__make} install \ |
123 | DESTDIR=$RPM_BUILD_ROOT | |
896b833c | 124 | |
61f848e8 | 125 | # just install instead of symlinking |
543fbe6c ER |
126 | rm -f $RPM_BUILD_ROOT%{_plugindir}/opensc-signer.so |
127 | mv -f $RPM_BUILD_ROOT%{_libdir}/opensc-signer.so $RPM_BUILD_ROOT%{_plugindir} | |
afd37b22 | 128 | |
61f848e8 | 129 | # default config |
4bdbfbe7 | 130 | install etc/opensc.conf $RPM_BUILD_ROOT%{_sysconfdir} |
1eb351c9 | 131 | |
61f848e8 | 132 | # useless (dlopened by *.so) |
18e38179 | 133 | rm -f $RPM_BUILD_ROOT%{_libdir}/{onepin-opensc,opensc,pkcs11}-*.{a,la} \ |
8d087e90 | 134 | $RPM_BUILD_ROOT%{_libdir}/opensc/*.{a,la} |
61f848e8 | 135 | |
896b833c | 136 | %clean |
137 | rm -rf $RPM_BUILD_ROOT | |
138 | ||
1cefa9cb JB |
139 | %post -p /sbin/ldconfig |
140 | %postun -p /sbin/ldconfig | |
896b833c | 141 | |
543fbe6c ER |
142 | %triggerin -n browser-plugin-opensc -- mozilla-firefox |
143 | %nsplugin_install -d %{_libdir}/mozilla-firefox/plugins opensc-signer.so | |
144 | ||
145 | %triggerun -n browser-plugin-opensc -- mozilla-firefox | |
146 | %nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins opensc-signer.so | |
147 | ||
148 | %triggerin -n browser-plugin-opensc -- mozilla | |
149 | %nsplugin_install -d %{_libdir}/mozilla/plugins opensc-signer.so | |
150 | ||
151 | %triggerun -n browser-plugin-opensc -- mozilla | |
152 | %nsplugin_uninstall -d %{_libdir}/mozilla/plugins opensc-signer.so | |
153 | ||
154 | %triggerin -n browser-plugin-opensc -- opera | |
155 | %nsplugin_install -d %{_libdir}/opera/plugins opensc-signer.so | |
156 | ||
157 | %triggerun -n browser-plugin-opensc -- opera | |
158 | %nsplugin_uninstall -d %{_libdir}/opera/plugins opensc-signer.so | |
159 | ||
160 | %triggerin -n browser-plugin-opensc -- konqueror | |
161 | %nsplugin_install -d %{_libdir}/kde3/plugins/konqueror opensc-signer.so | |
162 | ||
163 | %triggerun -n browser-plugin-opensc -- konqueror | |
164 | %nsplugin_uninstall -d %{_libdir}/kde3/plugins/konqueror opensc-signer.so | |
165 | ||
166 | %triggerin -n browser-plugin-opensc -- seamonkey | |
167 | %nsplugin_install -d %{_libdir}/seamonkey/plugins opensc-signer.so | |
168 | ||
169 | %triggerun -n browser-plugin-opensc -- seamonkey | |
170 | %nsplugin_uninstall -d %{_libdir}/seamonkey/plugins opensc-signer.so | |
171 | ||
172 | # as rpm removes the old obsoleted package files after the triggers | |
173 | # are ran, add another trigger to make the links there. | |
174 | %triggerpostun -n browser-plugin-opensc -- mozilla-plugin-opensc | |
175 | %nsplugin_install -f -d %{_libdir}/mozilla/plugins opensc-signer.so | |
176 | ||
896b833c | 177 | %files |
178 | %defattr(644,root,root,755) | |
88647e66 | 179 | %doc NEWS README doc/ChangeLog doc/{*.{html,css},html/tools.html} |
61f848e8 | 180 | %attr(755,root,root) %{_bindir}/cardos-info |
1cefa9cb | 181 | %attr(755,root,root) %{_bindir}/cryptoflex-tool |
8d087e90 JB |
182 | %attr(755,root,root) %{_bindir}/eidenv |
183 | %attr(755,root,root) %{_bindir}/netkey-tool | |
1cefa9cb JB |
184 | %attr(755,root,root) %{_bindir}/opensc-explorer |
185 | %attr(755,root,root) %{_bindir}/opensc-tool | |
88647e66 | 186 | %attr(755,root,root) %{_bindir}/piv-tool |
61f848e8 | 187 | %attr(755,root,root) %{_bindir}/pkcs11-tool |
1cefa9cb | 188 | %attr(755,root,root) %{_bindir}/pkcs15-* |
c39ac2c0 JB |
189 | %attr(755,root,root) %{_libdir}/libopensc.so.*.*.* |
190 | %attr(755,root,root) %{_libdir}/libpkcs15init.so.*.*.* | |
191 | %attr(755,root,root) %{_libdir}/libscconf.so.*.*.* | |
192 | %attr(755,root,root) %ghost %{_libdir}/libopensc.so.2 | |
193 | %attr(755,root,root) %ghost %{_libdir}/libpkcs15init.so.2 | |
194 | %attr(755,root,root) %ghost %{_libdir}/libscconf.so.2 | |
18e38179 | 195 | %attr(755,root,root) %{_libdir}/onepin-opensc-pkcs11.so |
2f74c13c | 196 | %attr(755,root,root) %{_libdir}/opensc-pkcs11.so |
8d087e90 | 197 | %attr(755,root,root) %{_libdir}/pkcs11-spy.so |
1cefa9cb | 198 | %dir %{_datadir}/opensc |
4bdbfbe7 JB |
199 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.conf |
200 | %config(noreplace) %verify(not md5 mtime size) %{_datadir}/opensc/*.profile | |
92519f5f | 201 | %{_mandir}/man1/cardos-info.1* |
61f848e8 | 202 | %{_mandir}/man1/cryptoflex-tool.1* |
8d087e90 | 203 | %{_mandir}/man1/netkey-tool.1* |
61f848e8 JB |
204 | %{_mandir}/man1/opensc-explorer.1* |
205 | %{_mandir}/man1/opensc-tool.1* | |
92519f5f JB |
206 | %{_mandir}/man1/pkcs11-tool.1* |
207 | %{_mandir}/man1/pkcs15-*.1* | |
c39ac2c0 | 208 | %{_mandir}/man5/pkcs15-profile.5* |
896b833c | 209 | |
210 | %files devel | |
211 | %defattr(644,root,root,755) | |
8d087e90 | 212 | %doc doc/html/api.html |
1cefa9cb JB |
213 | %attr(755,root,root) %{_bindir}/opensc-config |
214 | %attr(755,root,root) %{_libdir}/libopensc.so | |
215 | %attr(755,root,root) %{_libdir}/libpkcs15init.so | |
216 | %attr(755,root,root) %{_libdir}/libscconf.so | |
8d087e90 JB |
217 | %{_libdir}/libopensc.la |
218 | %{_libdir}/libpkcs15init.la | |
219 | %{_libdir}/libscconf.la | |
1cefa9cb | 220 | %{_includedir}/opensc |
c39ac2c0 JB |
221 | %{_pkgconfigdir}/libopensc.pc |
222 | %{_pkgconfigdir}/libpkcs15init.pc | |
223 | %{_pkgconfigdir}/libscconf.pc | |
61f848e8 | 224 | %{_mandir}/man1/opensc-config.1* |
c39ac2c0 | 225 | %{_mandir}/man3/sc_*.3* |
896b833c | 226 | |
227 | %files static | |
228 | %defattr(644,root,root,755) | |
8d087e90 JB |
229 | %{_libdir}/libopensc.a |
230 | %{_libdir}/libpkcs15init.a | |
231 | %{_libdir}/libscconf.a | |
d6f32863 | 232 | |
543fbe6c | 233 | %files -n browser-plugin-opensc |
d6f32863 | 234 | %defattr(644,root,root,755) |
543fbe6c | 235 | %attr(755,root,root) %{_plugindir}/opensc-signer.so |