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 static_libs # don't build static libraries
10 Summary: The BeeCrypt Cryptography Library
11 Summary(pl.UTF-8): Biblioteka kryptograficzna BeeCrypt
18 Source0: http://dl.sourceforge.net/project/beecrypt/beecrypt/%{version}/%{name}-%{version}.tar.gz
19 # Source0-md5: 8441c014170823f2dff97e33df55af1e
20 Patch0: %{name}-ac.patch
21 Patch1: %{name}-ac_python.patch
22 Patch2: %{name}-armv8.patch
23 URL: http://sourceforge.net/projects/beecrypt/
24 BuildRequires: autoconf >= 2.50
25 BuildRequires: automake
26 %if %{with java} && !%{with javac}
27 %ifarch i586 i686 athlon pentium3 pentium4 %{x8664}
30 BuildRequires: gcc-java
31 BuildRequires: libgcj-devel
34 %if %{with java} && %{with javac}
37 BuildRequires: libtool
39 BuildRequires: python-devel
40 BuildRequires: python-modules
41 BuildRequires: rpm-pythonprov
43 BuildRequires: rpmbuild(macros) >= 1.213
44 Obsoletes: beecrypt-doc
45 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
47 %define specflags_alpha -mno-explicit-relocs
48 %define specflags_pentium2 -mmmx
49 %define specflags_pentium3 -mmmx -msse
50 %define specflags_pentium4 -mmmx -msse -msse2
51 %define specflags_athlon -mmmx
54 BeeCrypt is an open source cryptography library that contains highly
55 optimized C and assembler implementations of many well-known
56 algorithms including Blowfish, MD5, SHA-1, Diffie-Hellman, and
59 %description -l pl.UTF-8
60 BeeCrypt jest open sourcową biblioteką, która zawiera wysoko
61 zoptymailzowane funkcje w C oraz assemblerze wielu algorytmów
62 szyfrowania m.in.: Blowfish, MD5, SHA-1, Diffie-Hellman oraz ElGamal.
65 Summary: The BeeCrypt Cryptography Library - development files
66 Summary(pl.UTF-8): Pliki dla programistów używających biblioteki BeeCrypt
67 Group: Development/Libraries
68 Requires: %{name} = %{epoch}:%{version}-%{release}
71 The BeeCrypt Cryptography Library - development files.
73 %description devel -l pl.UTF-8
74 Biblioteka kryptograficzna BeeCrypt - pliki dla programistów.
77 Summary: The BeeCrypt Cryptography Library - static library
78 Summary(pl.UTF-8): Biblioteka statyczna BeeCrypt
79 Group: Development/Libraries
80 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
83 The BeeCrypt Cryptography Library - static library.
85 %description static -l pl.UTF-8
86 Biblioteka statyczna BeeCrypt.
89 Summary: BeeCrypt Java glue library
90 Summary(pl.UTF-8): Biblioteka łącząca BeeCrypt z Javą
92 Requires: %{name} = %{epoch}:%{version}-%{release}
95 BeeCrypt Java glue library.
97 %description java -l pl.UTF-8
98 Biblioteka łącząca BeeCrypt z Javą.
101 Summary: Development files for BeeCrypt Java glue library
102 Summary(pl.UTF-8): Pliki programistyczne biblioteki łączącej Beecrypt z Javą
103 Group: Development/Libraries
104 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
105 Requires: %{name}-java = %{epoch}:%{version}-%{release}
107 %description java-devel
108 Development files for BeeCrypt Java glue library.
110 %description java-devel -l pl.UTF-8
111 Pliki programistyczne biblioteki łączącej Beecrypt z Javą.
114 Summary: BeeCrypt Java glue static library
115 Summary(pl.UTF-8): Statyczna biblioteka łącząca BeeCrypt z Javą
116 Group: Development/Libraries
117 Requires: %{name}-java-devel = %{epoch}:%{version}-%{release}
119 %description java-static
120 BeeCrypt Java glue static library.
122 %description java-static -l pl.UTF-8
123 Statyczna biblioteka łącząca BeeCrypt z Javą.
125 %package -n python-beecrypt
126 Summary: Python interface to BeeCrypt library
127 Summary(pl.UTF-8): Pythonowy interfejs do biblioteki BeeCrypt
128 Group: Development/Languages/Python
129 Requires: %{name} = %{epoch}:%{version}-%{release}
130 %pyrequires_eq python-libs
132 %description -n python-beecrypt
133 The python-beecrypt package contains a module which permits
134 applications written in the Python programming language to use the
135 interface supplied by BeeCrypt libraries.
137 %description -n python-beecrypt -l pl.UTF-8
138 Pakiet python-beecrypt zawiera moduł, który pozwala aplikacjom
139 napisanym w Pythonie na używanie interfejsu dostarczanego przez
148 # --with-cplusplus or building (even empty) *.cxx into libbeecrypt
149 # makes it (and thus rpm) depending on libstdc++ which is unacceptable
150 %{__perl} -pi -e 's/ cppglue\.cxx$//' Makefile.am
160 %{?with_javac:ac_cv_have_gcj=no} \
161 %{!?with_static_libs:--disable-static} \
162 --without-cplusplus \
163 --with%{!?with_java:out}-java \
164 %{!?with_python:--without-python}
169 rm -rf $RPM_BUILD_ROOT
170 install -d $RPM_BUILD_ROOT/%{_lib}
173 DESTDIR=$RPM_BUILD_ROOT
175 mv -f $RPM_BUILD_ROOT%{_libdir}/libbeecrypt.so.* $RPM_BUILD_ROOT/%{_lib}
176 ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libbeecrypt.so.*.*.*) \
177 $RPM_BUILD_ROOT%{_libdir}/libbeecrypt.so
179 %{?with_python:%{__rm} $RPM_BUILD_ROOT%{py_sitedir}/*.{la,a}}
182 rm -rf $RPM_BUILD_ROOT
184 %post -p /sbin/ldconfig
185 %postun -p /sbin/ldconfig
187 %post java -p /sbin/ldconfig
188 %postun java -p /sbin/ldconfig
191 %defattr(644,root,root,755)
192 %doc AUTHORS BENCHMARKS BUGS CONTRIBUTORS NEWS README
193 %attr(755,root,root) /%{_lib}/libbeecrypt.so.*.*.*
194 %attr(755,root,root) %ghost /%{_lib}/libbeecrypt.so.7
197 %defattr(644,root,root,755)
198 %attr(755,root,root) %{_libdir}/libbeecrypt.so
199 %{_libdir}/libbeecrypt.la
200 %{_includedir}/beecrypt
202 %if %{with static_libs}
204 %defattr(644,root,root,755)
205 %{_libdir}/libbeecrypt.a
210 %defattr(644,root,root,755)
211 %attr(755,root,root) %{_libdir}/libbeecrypt_java.so.*.*.*
212 %attr(755,root,root) %ghost %{_libdir}/libbeecrypt_java.so.7
215 %defattr(644,root,root,755)
216 %attr(755,root,root) %{_libdir}/libbeecrypt_java.so
217 %{_libdir}/libbeecrypt_java.la
219 %if %{with static_libs}
221 %defattr(644,root,root,755)
222 %{_libdir}/libbeecrypt_java.a
227 %files -n python-beecrypt
228 %defattr(644,root,root,755)
229 %attr(755,root,root) %{py_sitedir}/_bc.so