4 %define _ver %(echo %{version} | tr -d .)
5 Summary: Peter Gutmann's general purpose encryption library
6 Summary(pl.UTF-8): Biblioteka kryptograficzna ogólnego przeznaczenia Petera Gutmanna
12 Source0: ftp://ftp.franken.de/pub/crypt/cryptlib/cl%{_ver}.zip
13 # Source0-md5: afdb94894f7f798702703f4a95a2e7ac
14 Patch0: %{name}-rdtsc.patch
15 Patch1: %{name}-soname.patch
16 Patch2: optflags.patch
18 Patch4: format-security.patch
19 URL: http://www.cs.auckland.ac.nz/~pgut001/cryptlib/
20 BuildRequires: rpmbuild(macros) >= 1.710
21 BuildRequires: python-devel >= 1:2.5
22 BuildRequires: python-setuptools
23 BuildRequires: rpm-pythonprov
24 BuildRequires: sed >= 4.0
27 %pyrequires_eq python-modules
28 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31 The cryptlib encryption library provides an easy-to-use interface
32 which allows even inexperienced crypto programmers to easily add
33 strong encryption and authentication services to their software. The
34 library contains DES, triple DES, IDEA, MDC/SHS, RC2, RC4, RC5, SAFER,
35 SAFER-SK, Blowfish, and Blowfish-SK conventional encryption, MD2, MD4,
36 MD5, RIPEMD-160 and SHA hash algorithms, and Diffie-Hellman, DSA, and
37 RSA public-key encryption.
39 %description -l pl.UTF-8
40 Biblioteka kryptograficzna cryptlib udostępnia łatwy w użyciu
41 interfejs pozwalający nawet niedoświaczonym programistom kryptografii
42 łatwo dodawać do swoich programów usługi kryptograficzne i
43 uwierzytelnienia. Biblioteka zawiera szyfry konwencjonalne DES, 3DES,
44 IDEA, MDC/SHS, RC2, RC4, RC5, SAFER, SAFER-SK, Blowfish i Blowfish-SK,
45 algorytmy skrótu MD2, MD4, MD5, RIPEMD-160 i SHA oraz szyfry klucza
46 publicznego Diffie-Hellmana, DSA i RSA.
49 Summary: Header file for cryptlib library
50 Summary(pl.UTF-8): Plik nagłówkowy biblioteki cryptlib
51 Group: Development/Libraries
52 Requires: %{name} = %{version}-%{release}
55 The header file for developing applications that use the cryptlib
58 %description devel -l pl.UTF-8
59 Plik nagłówkowy do tworzenia aplikacji korzystających z biblioteki
60 kryptograficznej cryptlib.
63 Summary: Static cryptlib library
64 Summary(pl.UTF-8): Statyczna biblioteka cryptlib
65 Group: Development/Libraries
66 Requires: %{name}-devel = %{version}-%{release}
69 Static cryptlib library.
71 %description static -l pl.UTF-8
72 Statyczna biblioteka cryptlib.
74 %package -n python-cryptlib
75 Summary: Python bindings for cryptlib
76 Summary(pl.UTF-8): Wiązania języka Python do biblioteki cryptlib
77 Group: Libraries/Python
78 Requires: python >= 1:2.4
80 %description -n python-cryptlib
81 Python bindings for cryptlib library.
83 %description -n python-cryptlib -l pl.UTF-8
84 Wiązania języka Python do biblioteki cryptlib.
88 unzip -q -L -a %{SOURCE0}
98 OPTFLAGS="%{rpmcflags} -DOPENSSL_NO_ASM" \
101 OPTFLAGS="%{rpmcflags} -DUSE_ASM" \
103 OPTFLAGS="%{rpmcflags}" \
110 OPTFLAGS="%{rpmcflags} -DOPENSSL_NO_ASM" \
113 OPTFLAGS="%{rpmcflags} -DUSE_ASM" \
115 OPTFLAGS="%{rpmcflags}" \
120 ln -sf libcl.so.%{libver} libcl.so
126 rm -rf $RPM_BUILD_ROOT
127 install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir},%{py_sitedir}}
129 install cryptlib.h $RPM_BUILD_ROOT%{_includedir}
130 install libcl.a $RPM_BUILD_ROOT%{_libdir}
131 install libcl.so.%{libver} $RPM_BUILD_ROOT%{_libdir}
132 ln -s libcl.so.%{libver} $RPM_BUILD_ROOT%{_libdir}/libcl.so.3
133 ln -s libcl.so.%{libver} $RPM_BUILD_ROOT%{_libdir}/libcl.so
139 rm -rf $RPM_BUILD_ROOT
141 %post -p /sbin/ldconfig
142 %postun -p /sbin/ldconfig
145 %defattr(644,root,root,755)
146 %attr(755,root,root) %{_libdir}/libcl.so.%{libver}
147 %attr(755,root,root) %ghost %{_libdir}/libcl.so.3
150 %defattr(644,root,root,755)
151 %attr(755,root,root) %{_libdir}/libcl.so
152 %{_includedir}/cryptlib.h
155 %defattr(644,root,root,755)
158 %files -n python-cryptlib
159 %defattr(644,root,root,755)
160 %attr(755,root,root) %{py_sitedir}/cryptlib_py.so
161 %{py_sitedir}/cryptlib_py-*.egg-info