2 # WARNING: despite unchanged SONAME, the RSA ABI (and API) has changed since 3.x!
5 %bcond_without java # build with Java support
6 %bcond_with javac # use javac instead of gcj
7 %bcond_without python # don't build python module
8 %bcond_without doc # don't build documentation
9 %bcond_without static_libs # don't build static libraries
11 Summary: The BeeCrypt Cryptography Library
12 Summary(pl): Biblioteka kryptograficzna BeeCrypt
19 Source0: http://dl.sourceforge.net/beecrypt/%{name}-%{version}.tar.gz
20 # Source0-md5: 820d26437843ab0a6a8a5151a73a657c
21 Patch0: %{name}-opt.patch
22 Patch1: %{name}-lib64_fix.patch
23 Patch2: %{name}-ac_python.patch
24 URL: http://sourceforge.net/projects/beecrypt/
25 BuildRequires: autoconf >= 2.50
26 BuildRequires: automake
28 BuildRequires: doxygen
30 %if %{with java} && !%{with javac}
31 BuildRequires: gcc-java
34 BuildRequires: ghostscript
35 BuildRequires: graphviz
37 %if %{with java} && %{with javac}
40 BuildRequires: libtool
41 %if %{with java} && !%{with javac}
42 BuildRequires: libgcj-devel
45 BuildRequires: python-devel
46 BuildRequires: python-modules
48 BuildRequires: rpmbuild(macros) >= 1.213
50 BuildRequires: tetex-dvips
51 BuildRequires: tetex-format-latex
52 BuildRequires: tetex-latex-dstroke
53 # note: this is incorrect place, it should be somewhere in tetex packages
54 BuildRequires: tetex-metafont
56 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
58 %define specflags_alpha -mno-explicit-relocs
61 BeeCrypt is an open source cryptography library that contains highly
62 optimized C and assembler implementations of many well-known
63 algorithms including Blowfish, MD5, SHA-1, Diffie-Hellman, and
67 BeeCrypt jest open sourcow± bibliotek±, która zawiera wysoko
68 zoptymailzowane funkcje w C oraz assemblerze wielu algorytmów
69 szyfrowania m.in.: Blowfish, MD5, SHA-1, Diffie-Hellman oraz ElGamal.
72 Summary: The BeeCrypt Cryptography Library - development files
73 Summary(pl): Pliki dla programistów u¿ywaj±cych biblioteki BeeCrypt
74 Group: Development/Libraries
75 Requires: %{name} = %{epoch}:%{version}-%{release}
78 The BeeCrypt Cryptography Library - development files.
80 %description devel -l pl
81 Biblioteka kryptograficzna BeeCrypt - pliki dla programistów.
84 Summary: The BeeCrypt Cryptography Library - static library
85 Summary(pl): Biblioteka statyczna BeeCrypt
86 Group: Development/Libraries
87 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
90 The BeeCrypt Cryptography Library - static library.
92 %description static -l pl
93 Biblioteka statyczna BeeCrypt.
96 Summary: Development documentation for BeeCrypt
97 Summary(pl): Dokumentacja programisty dla biblioteki BeeCrypt
101 Development documentation for BeeCrypt.
103 %description doc -l pl
104 Dokumentacja programisty dla biblioteki BeeCrypt.
107 Summary: BeeCrypt Java glue library
108 Summary(pl): Biblioteka ³±cz±ca BeeCrypt z Jav±
110 Requires: %{name} = %{epoch}:%{version}-%{release}
113 BeeCrypt Java glue library.
115 %description java -l pl
116 Biblioteka ³±cz±ca BeeCrypt z Jav±.
119 Summary: Development files for BeeCrypt Java glue library
120 Summary(pl): Pliki programistyczne biblioteki ³±cz±cej Beecrypt z Jav±
121 Group: Development/Libraries
122 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
123 Requires: %{name}-java = %{epoch}:%{version}-%{release}
125 %description java-devel
126 Development files for BeeCrypt Java glue library.
128 %description java-devel -l pl
129 Pliki programistyczne biblioteki ³±cz±cej Beecrypt z Jav±.
132 Summary: BeeCrypt Java glue static library
133 Summary(pl): Statyczna biblioteka ³±cz±ca BeeCrypt z Jav±
134 Group: Development/Libraries
135 Requires: %{name}-java-devel = %{epoch}:%{version}-%{release}
137 %description java-static
138 BeeCrypt Java glue static library.
140 %description java-static -l pl
141 Statyczna biblioteka ³±cz±ca BeeCrypt z Jav±.
143 %package -n python-beecrypt
144 Summary: Python interface to BeeCrypt library
145 Summary(pl): Pythonowy interfejs do biblioteki BeeCrypt
146 Group: Development/Languages/Python
147 Requires: %{name} = %{epoch}:%{version}-%{release}
148 %pyrequires_eq python-libs
150 %description -n python-beecrypt
151 The python-beecrypt package contains a module which permits
152 applications written in the Python programming language to use the
153 interface supplied by BeeCrypt libraries.
155 %description -n python-beecrypt -l pl
156 Pakiet python-beecrypt zawiera modu³, który pozwala aplikacjom
157 napisanym w Pythonie na u¿ywanie interfejsu dostarczanego przez
166 # --with-cplusplus or building (even empty) *.cxx into libbeecrypt
167 # makes it (and thus rpm) depending on libstdc++ which is unacceptable
168 %{__perl} -pi -e 's/ cppglue\.cxx$//' Makefile.am
170 %{__perl} -pi -e 's/^GENERATE_LATEX .*/GENERATE_LATEX = NO/' Doxyfile.in
179 %{?with_javac:ac_cv_have_gcj=no} \
180 --without-cplusplus \
181 --with%{!?with_java:out}-java \
182 --with-cpu=%{_target_cpu} \
183 %{!?with_static_libs:--enable-static=no} \
187 --with-arch=%{_target_cpu} \
190 --with%{!?with_python:out}-python
202 rm -rf $RPM_BUILD_ROOT
203 install -d $RPM_BUILD_ROOT/%{_lib}
206 DESTDIR=$RPM_BUILD_ROOT
209 %{__make} install -C python \
210 DESTDIR=$RPM_BUILD_ROOT
213 mv -f $RPM_BUILD_ROOT%{_libdir}/libbeecrypt.so.*.*.* $RPM_BUILD_ROOT/%{_lib}
214 ln -sf /%{_lib}/$(cd $RPM_BUILD_ROOT/%{_lib} ; echo libbeecrypt.so.*.*.*) \
215 $RPM_BUILD_ROOT%{_libdir}/libbeecrypt.so
217 rm -f $RPM_BUILD_ROOT%{py_sitedir}/*.{la,a}
220 rm -rf $RPM_BUILD_ROOT
222 %post -p /sbin/ldconfig
223 %postun -p /sbin/ldconfig
225 %post java -p /sbin/ldconfig
226 %postun java -p /sbin/ldconfig
229 %defattr(644,root,root,755)
230 %doc AUTHORS BENCHMARKS BUGS CONTRIBUTORS NEWS README
231 %attr(755,root,root) /%{_lib}/libbeecrypt.so.*.*.*
234 %defattr(644,root,root,755)
235 %attr(755,root,root) %{_libdir}/libbeecrypt.so
236 %{_libdir}/libbeecrypt.la
237 %{_includedir}/beecrypt
239 %if %{with static_libs}
241 %defattr(644,root,root,755)
242 %{_libdir}/libbeecrypt.a
247 %defattr(644,root,root,755)
248 %attr(755,root,root) %{_libdir}/libbeecrypt_java.so.*.*.*
251 %defattr(644,root,root,755)
252 %attr(755,root,root) %{_libdir}/libbeecrypt_java.so
253 %{_libdir}/libbeecrypt_java.la
255 %if %{with static_libs}
257 %defattr(644,root,root,755)
258 %{_libdir}/libbeecrypt_java.a
264 %defattr(644,root,root,755)
269 %files -n python-beecrypt
270 %defattr(644,root,root,755)
271 %attr(755,root,root) %{py_sitedir}/*.so