]>
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 |
239c4950 | 4 | Version: 0.11.13 |
b725c008 | 5 | Release: 2 |
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 |
239c4950 | 10 | # Source0-md5: 98fa151e947941f9c3f27420fdf47c11 |
7af8549c JR |
11 | Source1: %{name}-initramfs-hook |
12 | Source2: %{name}-initramfs-local-bottom | |
13 | Source3: %{name}-initramfs-local-top | |
14 | Source4: %{name}-initramfs-README | |
c9f4880d JB |
15 | Patch0: %{name}-libassuan-2.patch |
16 | Patch1: %{name}-pcsc.patch | |
9c0288b5 | 17 | URL: http://www.opensc-project.org/ |
c28ca417 JB |
18 | BuildRequires: autoconf >= 2.60 |
19 | BuildRequires: automake >= 1:1.10 | |
c9f4880d | 20 | BuildRequires: libassuan-devel >= 1:2.0.0 |
8d087e90 | 21 | BuildRequires: libltdl-devel |
1cefa9cb | 22 | BuildRequires: libtool >= 1:1.4.2-9 |
d740a4df | 23 | BuildRequires: libxslt-progs |
543fbe6c | 24 | BuildRequires: openct-devel |
fcac1d33 | 25 | BuildRequires: openldap-devel >= 2.4.6 |
72eaba4f | 26 | BuildRequires: openssl-devel >= 0.9.7d |
c9f4880d | 27 | BuildRequires: pcsc-lite-devel >= 1.6.0 |
34f2d3c1 | 28 | BuildRequires: pkgconfig >= 1:0.9.0 |
1cefa9cb | 29 | BuildRequires: readline-devel |
c28ca417 | 30 | BuildRequires: rpmbuild(macros) >= 1.364 |
47974cd7 | 31 | BuildRequires: xorg-lib-libXt-devel |
c28ca417 | 32 | BuildRequires: zlib-devel |
c9f4880d | 33 | Requires: pcsc-lite-libs >= 1.6.0 |
896b833c | 34 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
35 | ||
1eb351c9 | 36 | # datadir is used for config files and (editable) profiles |
ac174bda JB |
37 | %define _datadir /etc |
38 | %define _sysconfdir /etc/opensc | |
d6f32863 | 39 | |
896b833c | 40 | %description |
1cefa9cb JB |
41 | libopensc is a library for accessing SmartCard devices using PC/SC |
42 | Lite middleware package. It is also the core library of the OpenSC | |
43 | project. Basic functionality (e.g. SELECT FILE, READ BINARY) should | |
44 | work on any ISO 7816-4 compatible SmartCard. Encryption and decryption | |
45 | using private keys on the SmartCard is at the moment possible only | |
46 | with PKCS#15 compatible cards, such as the FINEID (Finnish Electronic | |
47 | IDentity) card manufactured by Setec. | |
896b833c | 48 | |
8623b75b | 49 | %description -l pl.UTF-8 |
1cefa9cb | 50 | libopensc to biblioteka do korzystania z kart procesorowych przy |
8623b75b JR |
51 | użyciu pakietu warstwy pośredniej PC/SC Lite. Jest to także podstawowa |
52 | biblioteka projektu OpenSC. Podstawowa funkcjonalność (np. SELECT | |
53 | FILE, READ BINARY) powinna działać także z dowolną kartą procesorową | |
54 | zgodną z ISO-7816-4. Szyfrowanie i odszyfrowywanie przy użyciu | |
55 | prywatnych kluczy na karcie na razie jest możliwe tylko przy użyciu | |
1cefa9cb JB |
56 | kart kompatybilnych z PKCS#16, takich jak FINEID (Finnish Electronic |
57 | IDentity) produkowanych przez Setec. | |
896b833c | 58 | |
59 | %package devel | |
1cefa9cb | 60 | Summary: OpenSC development files |
ae88f326 | 61 | Summary(pl.UTF-8): Pliki dla programistów używających OpenSC |
896b833c | 62 | Group: Development/Tools |
9f872d80 | 63 | Requires: %{name} = %{epoch}:%{version}-%{release} |
24aae781 | 64 | Requires: libltdl-devel |
9f872d80 JB |
65 | Requires: openct-devel |
66 | Requires: openssl-devel | |
c9f4880d | 67 | Requires: pcsc-lite-devel >= 1.6.0 |
896b833c | 68 | |
69 | %description devel | |
1cefa9cb | 70 | OpenSC development files. |
896b833c | 71 | |
8623b75b JR |
72 | %description devel -l pl.UTF-8 |
73 | Pliki dla programistów używających OpenSC. | |
896b833c | 74 | |
75 | %package static | |
1cefa9cb | 76 | Summary: Static OpenSC libraries |
ae88f326 | 77 | Summary(pl.UTF-8): Bibloteki statyczne OpenSC |
896b833c | 78 | Group: Development/Tools |
9f872d80 | 79 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
896b833c | 80 | |
81 | %description static | |
1cefa9cb | 82 | Static OpenSC libraries. |
896b833c | 83 | |
8623b75b | 84 | %description static -l pl.UTF-8 |
1cefa9cb JB |
85 | Statyczne biblioteki OpenSC. |
86 | ||
543fbe6c | 87 | %package -n browser-plugin-opensc |
d6f32863 | 88 | Summary: OpenSC Signer plugin for Mozilla |
ae88f326 | 89 | Summary(pl.UTF-8): Wtyczka OpenSC Signer dla Mozilli |
d6f32863 | 90 | Group: X11/Applications |
9f872d80 | 91 | Requires: %{name} = %{epoch}:%{version}-%{release} |
c28ca417 | 92 | Requires: browser-plugins >= 2.0 |
543fbe6c | 93 | Requires: browser-plugins(%{_target_base_arch}) |
c28ca417 | 94 | Requires: pinentry >= 0.7.5-2 |
543fbe6c ER |
95 | Provides: mozilla-plugin-opensc |
96 | Obsoletes: mozilla-plugin-opensc | |
97 | ||
98 | %description -n browser-plugin-opensc | |
99 | OpenSC Signer browser plugin. | |
d6f32863 | 100 | |
543fbe6c | 101 | Supported browsers: %{browsers}. |
d6f32863 | 102 | |
8623b75b JR |
103 | %description -n browser-plugin-opensc -l pl.UTF-8 |
104 | Wtyczka OpenSC Signer dla przeglądarek. | |
543fbe6c | 105 | |
8623b75b | 106 | Obsługiwane przeglądarki: %{browsers}. |
d6f32863 | 107 | |
2504dc81 JR |
108 | %package initramfs |
109 | Summary: OpenSC support scripts for initramfs-tools | |
110 | Summary(pl.UTF-8): Skrypty dla initramfs-tools ze wsparciem dla OpenSC | |
111 | Group: Base | |
112 | Requires: %{name} = %{version}-%{release} | |
113 | Requires: initramfs-tools | |
114 | ||
115 | %description initramfs | |
116 | OpenSC support scripts for initramfs-tools. | |
117 | ||
118 | %description initramfs -l pl.UTF-8 | |
119 | Skrypty dla initramfs-tools ze wsparciem dla OpenSC. | |
120 | ||
896b833c | 121 | %prep |
1cefa9cb | 122 | %setup -q |
c9f4880d JB |
123 | %patch0 -p1 |
124 | %patch1 -p1 | |
896b833c | 125 | |
2504dc81 JR |
126 | install %{SOURCE4} README.initramfs |
127 | ||
896b833c | 128 | %build |
1cefa9cb | 129 | %{__libtoolize} |
c28ca417 | 130 | %{__aclocal} -I m4 |
1cefa9cb | 131 | %{__autoconf} |
ac174bda | 132 | %{__autoheader} |
1cefa9cb | 133 | %{__automake} |
d6f32863 | 134 | %configure \ |
c28ca417 JB |
135 | --enable-openct \ |
136 | --enable-nsplugin \ | |
137 | --enable-pcsc \ | |
138 | --with-pcsc-provider=%{_libdir}/libpcsclite.so.1 \ | |
34a5de28 | 139 | --with-pinentry=/usr/bin/pinentry \ |
c28ca417 | 140 | --with-plugindir=%{_browserpluginsdir} |
896b833c | 141 | |
1cefa9cb | 142 | %{__make} |
896b833c | 143 | |
144 | %install | |
145 | rm -rf $RPM_BUILD_ROOT | |
2504dc81 | 146 | install -d $RPM_BUILD_ROOT%{_browserpluginsdir} \ |
80eefb38 | 147 | $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/{hooks,scripts/local-{bottom,top}} |
1cefa9cb | 148 | |
61f848e8 JB |
149 | %{__make} install \ |
150 | DESTDIR=$RPM_BUILD_ROOT | |
896b833c | 151 | |
61f848e8 | 152 | # just install instead of symlinking |
c28ca417 JB |
153 | %{__rm} $RPM_BUILD_ROOT%{_browserpluginsdir}/opensc-signer.so |
154 | mv -f $RPM_BUILD_ROOT%{_libdir}/opensc-signer.so $RPM_BUILD_ROOT%{_browserpluginsdir} | |
afd37b22 | 155 | |
61f848e8 | 156 | # default config |
4bdbfbe7 | 157 | install etc/opensc.conf $RPM_BUILD_ROOT%{_sysconfdir} |
1eb351c9 | 158 | |
80eefb38 JR |
159 | install %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/hooks/opensc |
160 | install %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/scripts/local-bottom/opensc | |
161 | install %{SOURCE3} $RPM_BUILD_ROOT%{_datadir}/initramfs-tools/scripts/local-top/opensc | |
2504dc81 | 162 | |
61f848e8 | 163 | # useless (dlopened by *.so) |
18e38179 | 164 | rm -f $RPM_BUILD_ROOT%{_libdir}/{onepin-opensc,opensc,pkcs11}-*.{a,la} \ |
8d087e90 | 165 | $RPM_BUILD_ROOT%{_libdir}/opensc/*.{a,la} |
61f848e8 | 166 | |
896b833c | 167 | %clean |
168 | rm -rf $RPM_BUILD_ROOT | |
169 | ||
1cefa9cb JB |
170 | %post -p /sbin/ldconfig |
171 | %postun -p /sbin/ldconfig | |
896b833c | 172 | |
c28ca417 JB |
173 | %post -n browser-plugin-opensc |
174 | %update_browser_plugins | |
543fbe6c | 175 | |
c28ca417 JB |
176 | %postun -n browser-plugin-opensc |
177 | if [ "$1" = "0" ]; then | |
178 | %update_browser_plugins | |
179 | fi | |
543fbe6c | 180 | |
896b833c | 181 | %files |
182 | %defattr(644,root,root,755) | |
c28ca417 | 183 | %doc NEWS README doc/nonpersistent/{ChangeLog,wiki.out} doc/html.out/tools.html |
61f848e8 | 184 | %attr(755,root,root) %{_bindir}/cardos-info |
d9747ba8 | 185 | %attr(755,root,root) %{_bindir}/cardos-tool |
1cefa9cb | 186 | %attr(755,root,root) %{_bindir}/cryptoflex-tool |
8d087e90 JB |
187 | %attr(755,root,root) %{_bindir}/eidenv |
188 | %attr(755,root,root) %{_bindir}/netkey-tool | |
1cefa9cb JB |
189 | %attr(755,root,root) %{_bindir}/opensc-explorer |
190 | %attr(755,root,root) %{_bindir}/opensc-tool | |
88647e66 | 191 | %attr(755,root,root) %{_bindir}/piv-tool |
61f848e8 | 192 | %attr(755,root,root) %{_bindir}/pkcs11-tool |
1cefa9cb | 193 | %attr(755,root,root) %{_bindir}/pkcs15-* |
c28ca417 | 194 | %attr(755,root,root) %{_bindir}/rutoken-tool |
c9f4880d | 195 | %attr(755,root,root) %{_bindir}/westcos-tool |
c39ac2c0 | 196 | %attr(755,root,root) %{_libdir}/libopensc.so.*.*.* |
c39ac2c0 | 197 | %attr(755,root,root) %ghost %{_libdir}/libopensc.so.2 |
c28ca417 | 198 | %attr(755,root,root) %{_libdir}/libpkcs15init.so.*.*.* |
c39ac2c0 | 199 | %attr(755,root,root) %ghost %{_libdir}/libpkcs15init.so.2 |
c28ca417 | 200 | %attr(755,root,root) %{_libdir}/libscconf.so.*.*.* |
c39ac2c0 | 201 | %attr(755,root,root) %ghost %{_libdir}/libscconf.so.2 |
c28ca417 | 202 | # PKCS11 modules |
18e38179 | 203 | %attr(755,root,root) %{_libdir}/onepin-opensc-pkcs11.so |
2f74c13c | 204 | %attr(755,root,root) %{_libdir}/opensc-pkcs11.so |
8d087e90 | 205 | %attr(755,root,root) %{_libdir}/pkcs11-spy.so |
c28ca417 JB |
206 | %dir %{_libdir}/pkcs11 |
207 | %attr(755,root,root) %{_libdir}/pkcs11/onepin-opensc-pkcs11.so | |
208 | %attr(755,root,root) %{_libdir}/pkcs11/opensc-pkcs11.so | |
209 | %attr(755,root,root) %{_libdir}/pkcs11/pkcs11-spy.so | |
1cefa9cb | 210 | %dir %{_datadir}/opensc |
c9f4880d | 211 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/opensc.conf |
4bdbfbe7 | 212 | %config(noreplace) %verify(not md5 mtime size) %{_datadir}/opensc/*.profile |
d9747ba8 | 213 | %{_mandir}/man1/cardos-tool.1* |
61f848e8 | 214 | %{_mandir}/man1/cryptoflex-tool.1* |
8d087e90 | 215 | %{_mandir}/man1/netkey-tool.1* |
61f848e8 JB |
216 | %{_mandir}/man1/opensc-explorer.1* |
217 | %{_mandir}/man1/opensc-tool.1* | |
92519f5f JB |
218 | %{_mandir}/man1/pkcs11-tool.1* |
219 | %{_mandir}/man1/pkcs15-*.1* | |
c9f4880d | 220 | %{_mandir}/man1/westcos-tool.1* |
c39ac2c0 | 221 | %{_mandir}/man5/pkcs15-profile.5* |
896b833c | 222 | |
223 | %files devel | |
224 | %defattr(644,root,root,755) | |
c28ca417 | 225 | %doc doc/html.out/api.html |
1cefa9cb JB |
226 | %attr(755,root,root) %{_bindir}/opensc-config |
227 | %attr(755,root,root) %{_libdir}/libopensc.so | |
228 | %attr(755,root,root) %{_libdir}/libpkcs15init.so | |
229 | %attr(755,root,root) %{_libdir}/libscconf.so | |
8d087e90 JB |
230 | %{_libdir}/libopensc.la |
231 | %{_libdir}/libpkcs15init.la | |
232 | %{_libdir}/libscconf.la | |
1cefa9cb | 233 | %{_includedir}/opensc |
c39ac2c0 JB |
234 | %{_pkgconfigdir}/libopensc.pc |
235 | %{_pkgconfigdir}/libpkcs15init.pc | |
236 | %{_pkgconfigdir}/libscconf.pc | |
61f848e8 | 237 | %{_mandir}/man1/opensc-config.1* |
c39ac2c0 | 238 | %{_mandir}/man3/sc_*.3* |
896b833c | 239 | |
240 | %files static | |
241 | %defattr(644,root,root,755) | |
8d087e90 JB |
242 | %{_libdir}/libopensc.a |
243 | %{_libdir}/libpkcs15init.a | |
244 | %{_libdir}/libscconf.a | |
d6f32863 | 245 | |
543fbe6c | 246 | %files -n browser-plugin-opensc |
d6f32863 | 247 | %defattr(644,root,root,755) |
c28ca417 | 248 | %attr(755,root,root) %{_browserpluginsdir}/opensc-signer.so |
2504dc81 JR |
249 | |
250 | %files initramfs | |
251 | %defattr(644,root,root,755) | |
252 | %doc README.initramfs | |
253 | %attr(755,root,root) %{_datadir}/initramfs-tools/hooks/opensc | |
254 | %attr(755,root,root) %{_datadir}/initramfs-tools/scripts/local-top/opensc | |
255 | %attr(755,root,root) %{_datadir}/initramfs-tools/scripts/local-bottom/opensc |