]> git.pld-linux.org Git - packages/cryptlib.git/blob - cryptlib.spec
- set libcl soname
[packages/cryptlib.git] / cryptlib.spec
1 #
2 %define         libver  3.3.0
3 #
4 Summary:        Peter Gutmann's general purpose encryption library
5 Summary(pl.UTF-8):      Biblioteka kryptograficzna ogólnego przeznaczenia Petera Gutmanna
6 Name:           cryptlib
7 Version:        3.3.1
8 Release:        0.1
9 License:        sleepycat
10 Group:          Libraries
11 Source0:        ftp://ftp.franken.de/pub/crypt/cryptlib/cl331.zip
12 # Source0-md5:  3e93e5aa0b33fb1d5b05b099f01e0afe
13 URL:            http://www.cs.auckland.ac.nz/~pgut001/cryptlib/
14 BuildRequires:  sed >= 4.0
15 BuildRequires:  unzip
16 BuildRequires:  python-devel
17 BuildRequires:  python-setuptools
18 BuildRequires:  rpm-pythonprov
19 %pyrequires_eq  python-modules
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21 Provides:       libcl.so
22
23 %description
24 The cryptlib encryption library provides an easy-to-use interface
25 which allows even inexperienced crypto programmers to easily add
26 strong encryption and authentication services to their software. The
27 library contains DES, triple DES, IDEA, MDC/SHS, RC2, RC4, RC5, SAFER,
28 SAFER-SK, Blowfish, and Blowfish-SK conventional encryption, MD2, MD4,
29 MD5, RIPEMD-160 and SHA hash algorithms, and Diffie-Hellman, DSA, and
30 RSA public-key encryption.
31
32 %description -l pl.UTF-8
33 Biblioteka kryptograficzna cryptlib udostępnia łatwy w użyciu
34 interfejs pozwalający nawet niedoświaczonym programistom kryptografii
35 łatwo dodawać do swoich programów usługi kryptograficzne i
36 uwierzytelnienia. Biblioteka zawiera szyfry konwencjonalne DES, 3DES,
37 IDEA, MDC/SHS, RC2, RC4, RC5, SAFER, SAFER-SK, Blowfish i Blowfish-SK,
38 algorytmy skrótu MD2, MD4, MD5, RIPEMD-160 i SHA oraz szyfry klucza
39 publicznego Diffie-Hellmana, DSA i RSA.
40
41 %package devel
42 Summary:        Header file for cryptlib library
43 Summary(pl.UTF-8):      Plik nagłówkowy biblioteki cryptlib
44 Group:          Development/Libraries
45 Requires:       %{name} = %{version}-%{release}
46
47 %description devel
48 The header file for developing applications that use the cryptlib
49 cryptography library.
50
51 %description devel -l pl.UTF-8
52 Plik nagłówkowy do tworzenia aplikacji korzystających z biblioteki
53 kryptograficznej cryptlib.
54
55 %package static
56 Summary:        Static cryptlib library
57 Summary(pl.UTF-8):      Statyczna biblioteka cryptlib
58 Group:          Development/Libraries
59 Requires:       %{name}-devel = %{version}-%{release}
60
61 %description static
62 Static cryptlib library.
63
64 %description static -l pl.UTF-8
65 Statyczna biblioteka cryptlib.
66
67 %package -n python-cryptlib
68 Summary:        Python bindings for cryptlib
69 Summary(pl.UTF-8):      Wiązania języka Python do biblioteki cryptlib
70 Group:          Libraries/Python
71 Requires:       python >= 1:2.4
72
73 %description -n python-cryptlib
74 Python bindings for cryptlib library.
75
76 %description -n python-cryptlib -l pl.UTF-8
77 Wiązania języka Python do biblioteki cryptlib.
78
79 %prep
80 %setup -q -T -c
81 unzip -L -a %{SOURCE0}
82
83 sed -i -e 's/ -O3 / %{rpmcflags} /' makefile
84
85 %build
86 %{__make} \
87         CC="%{__cc}"
88
89 %{__make} shared \
90         CC="%{__cc}"
91
92 ln -sf libcl.so.%{libver} libcl.so
93
94 cd bindings
95 python setup.py build
96
97 %install
98 rm -rf $RPM_BUILD_ROOT
99 install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir},%{py_sitedir}}
100
101 install cryptlib.h $RPM_BUILD_ROOT%{_includedir}
102 install libcl.a $RPM_BUILD_ROOT%{_libdir}
103 install libcl.so.%{libver} $RPM_BUILD_ROOT%{_libdir}
104 ln -s %{_libdir}/libcl.so.%{libver} $RPM_BUILD_ROOT%{_libdir}/libcl.so
105
106 cd bindings
107 python setup.py install \
108         --optimize=2    \
109         --root=$RPM_BUILD_ROOT
110
111 %clean
112 rm -rf $RPM_BUILD_ROOT
113
114 %post   -p /sbin/ldconfig
115 %postun -p /sbin/ldconfig
116
117 %files
118 %defattr(644,root,root,755)
119 %attr(755,root,root) %{_libdir}/libcl.so.%{libver}
120 %{_libdir}/libcl.so
121
122 %files devel
123 %defattr(644,root,root,755)
124 %{_includedir}/cryptlib.h
125
126 %files static
127 %defattr(644,root,root,755)
128 %{_libdir}/libcl.a
129
130 %files -n python-cryptlib
131 %defattr(644,root,root,755)
132 %attr(755,root,root) %{py_sitedir}/*.so
This page took 0.05494 seconds and 3 git commands to generate.