]> git.pld-linux.org Git - packages/opensc.git/blob - opensc.spec
- updated to 0.11.1
[packages/opensc.git] / opensc.spec
1 Summary:        OpenSC library - for accessing SmartCard devices using PC/SC Lite
2 Summary(pl):    Biblioteka OpenSC - do korzystania z kart procesorowych przy u¿yciu PC/SC Lite
3 Name:           opensc
4 Version:        0.11.1
5 Release:        1
6 Epoch:          0
7 License:        LGPL
8 Group:          Applications
9 Source0:        http://www.opensc-project.org/files/opensc/%{name}-%{version}.tar.gz
10 # Source0-md5:  94ce00a6bda38fac10ab06f5d5d1a8c3
11 Patch0:         %{name}-explorer-debug.patch
12 Patch1:         %{name}-libassuan.patch
13 URL:            http://www.opensc-project.org/
14 BuildRequires:  autoconf >= 2.52
15 BuildRequires:  automake
16 BuildRequires:  libassuan-devel >= 1:0.6.0
17 BuildRequires:  libltdl-devel
18 BuildRequires:  libtool >= 1:1.4.2-9
19 BuildRequires:  openct-devel
20 BuildRequires:  openldap-devel
21 BuildRequires:  openssl-devel >= 0.9.7d
22 BuildRequires:  pcsc-lite-devel
23 BuildRequires:  pkgconfig >= 1:0.9.0
24 BuildRequires:  readline-devel
25 BuildRequires:  rpmbuild(macros) >= 1.236
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 # datadir is used for config files and (editable) profiles
29 %define         _datadir        /etc
30 %define         _sysconfdir     /etc/opensc
31 %define         _plugindir      %{_libdir}/browser-plugins
32
33 # TODO: galeon and skipstone.
34 # use macro, otherwise extra LF inserted along with the ifarch
35 %define browsers mozilla, mozilla-firefox, konqueror, opera, seamonkey
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
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):    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
70 Pliki dla programistów u¿ywaj±cych OpenSC.
71
72 %package static
73 Summary:        Static OpenSC libraries
74 Summary(pl):    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
82 Statyczne biblioteki OpenSC.
83
84 %package -n browser-plugin-opensc
85 Summary:        OpenSC Signer plugin for Mozilla
86 Summary(pl):    Wtyczka OpenSC Signer dla Mozilli
87 Group:          X11/Applications
88 Requires:       %{name} = %{epoch}:%{version}-%{release}
89 Requires:       browser-plugins(%{_target_base_arch})
90 Requires:       pinentry-gtk
91 Provides:       mozilla-plugin-opensc
92 Obsoletes:      mozilla-plugin-opensc
93
94 %description -n browser-plugin-opensc
95 OpenSC Signer browser plugin.
96
97 Supported browsers: %{browsers}.
98
99 %description -n browser-plugin-opensc -l pl
100 Wtyczka OpenSC Signer dla przegl±darek.
101
102 Obs³ugiwane przegl±darki: %{browsers}.
103
104 %prep
105 %setup -q
106 %patch0 -p1
107 %patch1 -p1
108
109 %build
110 %{__libtoolize}
111 %{__aclocal} -I aclocal
112 %{__autoconf}
113 %{__autoheader}
114 %{__automake}
115 %configure \
116         --with-pin-entry=/usr/bin/pinentry-gtk \
117         --with-plugin-dir="%{_plugindir}"
118
119 %{__make}
120
121 %install
122 rm -rf $RPM_BUILD_ROOT
123 install -d $RPM_BUILD_ROOT%{_plugindir}
124
125 %{__make} install \
126         DESTDIR=$RPM_BUILD_ROOT
127
128 # just install instead of symlinking
129 rm -f $RPM_BUILD_ROOT%{_plugindir}/opensc-signer.so
130 mv -f $RPM_BUILD_ROOT%{_libdir}/opensc-signer.so $RPM_BUILD_ROOT%{_plugindir}
131
132 # default config
133 install etc/opensc.conf $RPM_BUILD_ROOT%{_sysconfdir}
134
135 # useless (dlopened by *.so)
136 rm -f $RPM_BUILD_ROOT%{_libdir}/{opensc,pkcs11}-*.{a,la} \
137         $RPM_BUILD_ROOT%{_libdir}/opensc/*.{a,la}
138
139 %clean
140 rm -rf $RPM_BUILD_ROOT
141
142 %post   -p /sbin/ldconfig
143 %postun -p /sbin/ldconfig
144
145 %triggerin -n browser-plugin-opensc -- mozilla-firefox
146 %nsplugin_install -d %{_libdir}/mozilla-firefox/plugins opensc-signer.so
147
148 %triggerun -n browser-plugin-opensc -- mozilla-firefox
149 %nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins opensc-signer.so
150
151 %triggerin -n browser-plugin-opensc -- mozilla
152 %nsplugin_install -d %{_libdir}/mozilla/plugins opensc-signer.so
153
154 %triggerun -n browser-plugin-opensc -- mozilla
155 %nsplugin_uninstall -d %{_libdir}/mozilla/plugins opensc-signer.so
156
157 %triggerin -n browser-plugin-opensc -- opera
158 %nsplugin_install -d %{_libdir}/opera/plugins opensc-signer.so
159
160 %triggerun -n browser-plugin-opensc -- opera
161 %nsplugin_uninstall -d %{_libdir}/opera/plugins opensc-signer.so
162
163 %triggerin -n browser-plugin-opensc -- konqueror
164 %nsplugin_install -d %{_libdir}/kde3/plugins/konqueror opensc-signer.so
165
166 %triggerun -n browser-plugin-opensc -- konqueror
167 %nsplugin_uninstall -d %{_libdir}/kde3/plugins/konqueror opensc-signer.so
168
169 %triggerin -n browser-plugin-opensc -- seamonkey
170 %nsplugin_install -d %{_libdir}/seamonkey/plugins opensc-signer.so
171
172 %triggerun -n browser-plugin-opensc -- seamonkey
173 %nsplugin_uninstall -d %{_libdir}/seamonkey/plugins opensc-signer.so
174
175 # as rpm removes the old obsoleted package files after the triggers
176 # are ran, add another trigger to make the links there.
177 %triggerpostun -n browser-plugin-opensc -- mozilla-plugin-opensc
178 %nsplugin_install -f -d %{_libdir}/mozilla/plugins opensc-signer.so
179
180 %files
181 %defattr(644,root,root,755)
182 %doc NEWS README doc/ChangeLog doc/{*.{html,css},html/tools.html}
183 %attr(755,root,root) %{_bindir}/cardos-info
184 %attr(755,root,root) %{_bindir}/cryptoflex-tool
185 %attr(755,root,root) %{_bindir}/eidenv
186 %attr(755,root,root) %{_bindir}/netkey-tool
187 %attr(755,root,root) %{_bindir}/opensc-explorer
188 %attr(755,root,root) %{_bindir}/opensc-tool
189 %attr(755,root,root) %{_bindir}/piv-tool
190 %attr(755,root,root) %{_bindir}/pkcs11-tool
191 %attr(755,root,root) %{_bindir}/pkcs15-*
192 %attr(755,root,root) %{_libdir}/lib*.so.*.*
193 %attr(755,root,root) %{_libdir}/opensc-pkcs11.so
194 %attr(755,root,root) %{_libdir}/pkcs11-spy.so
195 %dir %{_datadir}/opensc
196 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.conf
197 %config(noreplace) %verify(not md5 mtime size) %{_datadir}/opensc/*.profile
198 %{_mandir}/man1/cardos-info.1*
199 %{_mandir}/man1/cryptoflex-tool.1*
200 %{_mandir}/man1/netkey-tool.1*
201 %{_mandir}/man1/opensc-explorer.1*
202 %{_mandir}/man1/opensc-tool.1*
203 %{_mandir}/man1/pkcs11-tool.1*
204 %{_mandir}/man1/pkcs15-*.1*
205 %{_mandir}/man[57]/*
206
207 %files devel
208 %defattr(644,root,root,755)
209 %doc doc/html/api.html
210 %attr(755,root,root) %{_bindir}/opensc-config
211 %attr(755,root,root) %{_libdir}/libopensc.so
212 %attr(755,root,root) %{_libdir}/libpkcs15init.so
213 %attr(755,root,root) %{_libdir}/libscconf.so
214 %{_libdir}/libopensc.la
215 %{_libdir}/libpkcs15init.la
216 %{_libdir}/libscconf.la
217 %{_includedir}/opensc
218 %{_pkgconfigdir}/*.pc
219 %{_mandir}/man1/opensc-config.1*
220 %{_mandir}/man3/*
221
222 %files static
223 %defattr(644,root,root,755)
224 %{_libdir}/libopensc.a
225 %{_libdir}/libpkcs15init.a
226 %{_libdir}/libscconf.a
227
228 %files -n browser-plugin-opensc
229 %defattr(644,root,root,755)
230 %attr(755,root,root) %{_plugindir}/opensc-signer.so
This page took 0.038936 seconds and 3 git commands to generate.