]> git.pld-linux.org Git - packages/opensc.git/blob - opensc.spec
c663b0b3d6576bdecd7e0c86bb46d3779ecadc08
[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.7.0
5 Release:        2
6 License:        LGPL
7 Group:          Applications
8 Source0:        http://www.opensc.org/files/%{name}-%{version}.tar.gz
9 # Source0-md5:  12a6afb94a947065d9d0a4eaf91cb15e
10 Patch0:         %{name}-nolibs.patch
11 Patch1:         %{name}-segv.patch
12 Patch2:         %{name}-lt.patch
13 Patch3:         %{name}-ssl0.9.7.patch
14 Patch4:         %{name}-cryptoflex.patch
15 Patch5:         %{name}-pkcs15init-help.patch
16 URL:            http://www.opensc.org/
17 BuildRequires:  autoconf >= 2.52
18 BuildRequires:  automake
19 BuildRequires:  libassuan-devel
20 BuildRequires:  libtool >= 1:1.4.2-9
21 BUildRequires:  openldap-devel
22 BuildRequires:  openssl-devel
23 BuildRequires:  pam-devel
24 BuildRequires:  pcsc-lite-devel
25 BuildRequires:  readline-devel
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 # datadir is used for config files and (editable) profiles
29 %define         _datadir        %{_sysconfdir}
30 %define         mozplugindir    /usr/lib/mozilla/plugins
31
32 %description
33 libopensc is a library for accessing SmartCard devices using PC/SC
34 Lite middleware package. It is also the core library of the OpenSC
35 project. Basic functionality (e.g. SELECT FILE, READ BINARY) should
36 work on any ISO 7816-4 compatible SmartCard. Encryption and decryption
37 using private keys on the SmartCard is at the moment possible only
38 with PKCS#15 compatible cards, such as the FINEID (Finnish Electronic
39 IDentity) card manufactured by Setec.
40
41 %description -l pl
42 libopensc to biblioteka do korzystania z kart procesorowych przy
43 u¿yciu pakietu warstwy po¶redniej PC/SC Lite. Jest to tak¿e podstawowa
44 biblioteka projektu OpenSC. Podstawowa funkcjonalno¶æ (np. SELECT
45 FILE, READ BINARY) powinna dzia³aæ tak¿e z dowoln± kart± procesorow±
46 zgodn± z ISO-7816-4. Szyfrowanie i odszyfrowywanie przy u¿yciu
47 prywatnych kluczy na karcie na razie jest mo¿liwe tylko przy u¿yciu
48 kart kompatybilnych z PKCS#16, takich jak FINEID (Finnish Electronic
49 IDentity) produkowanych przez Setec.
50
51 %package devel
52 Summary:        OpenSC development files
53 Summary(pl):    Pliki dla programistów u¿ywaj±cych OpenSC
54 Group:          Development/Tools
55 Requires:       %{name} = %{version}
56
57 %description devel
58 OpenSC development files.
59
60 %description devel -l pl
61 Pliki dla programistów u¿ywaj±cych OpenSC.
62
63 %package static
64 Summary:        Static OpenSC libraries
65 Summary(pl):    Bibloteki statyczne OpenSC
66 Group:          Development/Tools
67 Requires:       %{name}-devel = %{version}
68
69 %description static
70 Static OpenSC libraries.
71
72 %description static -l pl
73 Statyczne biblioteki OpenSC.
74
75 %package -n pam_opensc
76 Summary:        OpenSC module for PAM
77 Summary(pl):    Modu³ PAM OpenSC
78 License:        GPL
79 Group:          Base
80 Requires:       %{name} = %{version}
81
82 %description -n pam_opensc
83 OpenSC module for PAM.
84
85 %description -n pam_opensc -l pl
86 Modu³ PAM OpenSC.
87
88 %package -n mozilla-plugin-opensc
89 Summary:        OpenSC Signer plugin for Mozilla
90 Summary(pl):    Wtyczka OpenSC Signer dla Mozilli
91 # libassuan is GPL
92 License:        GPL
93 Group:          X11/Applications
94 Requires:       %{name} = %{version}
95 Requires:       pinentry-gtk
96
97 %description -n mozilla-plugin-opensc
98 OpenSC Signer plugin for Mozilla.
99
100 %description -n mozilla-plugin-opensc -l pl
101 Wtyczka OpenSC Signer dla Mozilli.
102
103 %prep
104 %setup -q
105 %patch0 -p1
106 %patch1 -p1
107 %patch2 -p1
108 %patch3 -p1
109 %patch4 -p1
110 %patch5 -p1
111
112 %build
113 %{__libtoolize}
114 %{__aclocal}
115 %{__autoconf}
116 %{__automake}
117 %configure \
118         --with-pin-entry=/usr/bin/pinentry-gtk \
119         --with-plugin-dir="%{mozplugindir}"
120
121 %{__make}
122
123 %install
124 rm -rf $RPM_BUILD_ROOT
125
126 %{__make} install DESTDIR=$RPM_BUILD_ROOT
127
128 install -d $RPM_BUILD_ROOT/lib
129 mv -f $RPM_BUILD_ROOT%{_libdir}/security $RPM_BUILD_ROOT/lib
130
131 # libscam.a is broken (contains libscrandom.a) and not needed (static module)
132 rm -f $RPM_BUILD_ROOT%{_libdir}/libscam.{a,la}
133
134 mv -f $RPM_BUILD_ROOT%{_datadir}/opensc/opensc.conf{.example,}
135 mv -f $RPM_BUILD_ROOT%{_datadir}/opensc/scldap.conf{.example,}
136
137 %clean
138 rm -rf $RPM_BUILD_ROOT
139
140 %post   -p /sbin/ldconfig
141 %postun -p /sbin/ldconfig
142
143 %files
144 %defattr(644,root,root,755)
145 %doc AUTHORS ChangeLog NEWS README README.signer THANKS TODO docs/pkcs-15v1_1.asn
146 %attr(755,root,root) %{_bindir}/cryptoflex-tool
147 %attr(755,root,root) %{_bindir}/opensc-explorer
148 %attr(755,root,root) %{_bindir}/opensc-tool
149 %attr(755,root,root) %{_bindir}/pkcs15-*
150 %attr(755,root,root) %{_libdir}/lib*.so.*.*
151 %attr(755,root,root) %{_libdir}/libscam.so
152 %dir %{_libdir}/pkcs11
153 %attr(755,root,root) %{_libdir}/pkcs11/opensc-pkcs11.so
154 %dir %{_datadir}/opensc
155 %config(noreplace) %verify(not size mtime md5) %{_datadir}/opensc/*.conf
156 %config(noreplace) %verify(not size mtime md5) %{_datadir}/opensc/*.profile
157 %{_mandir}/man[157]/pkcs15*
158
159 %files devel
160 %defattr(644,root,root,755)
161 %attr(755,root,root) %{_bindir}/opensc-config
162 %attr(755,root,root) %{_libdir}/libopensc.so
163 %attr(755,root,root) %{_libdir}/libpkcs15init.so
164 %attr(755,root,root) %{_libdir}/libscconf.so
165 %attr(755,root,root) %{_libdir}/libscldap.so
166 %{_libdir}/libopensc.la
167 %{_libdir}/libpkcs15init.la
168 %{_libdir}/libscconf.la
169 %{_libdir}/libscldap.la
170 %{_libdir}/libscrandom.a
171 %{_includedir}/opensc
172
173 %files static
174 %defattr(644,root,root,755)
175 %{_libdir}/libopensc.a
176 %{_libdir}/libpkcs15init.a
177 %{_libdir}/libscconf.a
178 %{_libdir}/libscldap.a
179
180 %files -n pam_opensc
181 %defattr(644,root,root,755)
182 %attr(755,root,root) /lib/security/pam_opensc.so
183
184 %files -n mozilla-plugin-opensc
185 %defattr(644,root,root,755)
186 %attr(755,root,root) %{mozplugindir}/opensc-signer.so
This page took 0.030939 seconds and 2 git commands to generate.