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