]> git.pld-linux.org Git - packages/beecrypt.git/blame - beecrypt.spec
- BR: rpm-pythonprov
[packages/beecrypt.git] / beecrypt.spec
CommitLineData
d97ff880 1#
4d383701 2# WARNING: despite unchanged SONAME, the RSA ABI (and API) has changed since 3.x!
5bdc9e19 3#
d97ff880 4# Conditional build:
32db796d 5%bcond_without java # build with Java support
5bdc9e19 6%bcond_with javac # use javac instead of gcj
9c971131 7%bcond_without python # don't build python module
7fbed49d 8%bcond_without doc # don't build documentation
01129d60 9%bcond_without static_libs # don't build static libraries
d97ff880 10#
91407a9e 11Summary: The BeeCrypt Cryptography Library
6da54b22 12Summary(pl.UTF-8): Biblioteka kryptograficzna BeeCrypt
91407a9e 13Name: beecrypt
5bdc9e19 14Version: 4.1.2
d198d7e0 15Release: 6
22964bea 16Epoch: 2
91407a9e 17License: LGPL
d97ff880 18Group: Libraries
049b6d8b 19Source0: http://dl.sourceforge.net/beecrypt/%{name}-%{version}.tar.gz
5bdc9e19 20# Source0-md5: 820d26437843ab0a6a8a5151a73a657c
6f800bf2 21Patch0: %{name}-opt.patch
1b30549c 22Patch1: %{name}-lib64_fix.patch
c0fd553b 23Patch2: %{name}-ac_python.patch
63fbc33d 24URL: http://sourceforge.net/projects/beecrypt/
e7d47e5c 25BuildRequires: autoconf >= 2.50
d97ff880 26BuildRequires: automake
7fbed49d 27%if %{with doc}
d48e1138 28BuildRequires: doxygen
7fbed49d 29%endif
32db796d 30%if %{with java} && !%{with javac}
2f43e48b
AM
31%ifarch i586 i686 athlon pentium3 pentium4 %{x8664}
32BuildRequires: jdk
33%else
9c12ea62 34BuildRequires: gcc-java
710e653a 35BuildRequires: libgcj-devel
2f43e48b 36%endif
5bdc9e19 37%endif
7fbed49d 38%if %{with doc}
d77df8a9 39BuildRequires: ghostscript
2c40516b 40BuildRequires: graphviz
7fbed49d 41%endif
32db796d 42%if %{with java} && %{with javac}
5bdc9e19
JB
43BuildRequires: jdk
44%endif
d97ff880 45BuildRequires: libtool
c0fd553b 46%if %{with python}
47BuildRequires: python-devel
48BuildRequires: python-modules
f06a4408 49BuildRequires: rpm-pythonprov
c0fd553b 50%endif
442e4fde 51BuildRequires: rpmbuild(macros) >= 1.213
7fbed49d 52%if %{with doc}
d77df8a9
JB
53BuildRequires: tetex-dvips
54BuildRequires: tetex-format-latex
55BuildRequires: tetex-latex-dstroke
1349ca4d 56# note: this is incorrect place, it should be somewhere in tetex packages
57BuildRequires: tetex-metafont
7fbed49d 58%endif
63fbc33d 59BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
91407a9e 60
049b6d8b 61%define specflags_alpha -mno-explicit-relocs
19d4c14b 62
91407a9e 63%description
64BeeCrypt is an open source cryptography library that contains highly
65optimized C and assembler implementations of many well-known
66algorithms including Blowfish, MD5, SHA-1, Diffie-Hellman, and
67ElGamal.
68
42d161bc
JR
69%description -l pl.UTF-8
70BeeCrypt jest open sourcową biblioteką, która zawiera wysoko
71zoptymailzowane funkcje w C oraz assemblerze wielu algorytmów
5293cd2f 72szyfrowania m.in.: Blowfish, MD5, SHA-1, Diffie-Hellman oraz ElGamal.
91407a9e 73
81aa497c 74%package devel
75Summary: The BeeCrypt Cryptography Library - development files
6da54b22 76Summary(pl.UTF-8): Pliki dla programistów używających biblioteki BeeCrypt
81aa497c 77Group: Development/Libraries
82780c6a 78Requires: %{name} = %{epoch}:%{version}-%{release}
81aa497c 79
91407a9e 80%description devel
81aa497c 81The BeeCrypt Cryptography Library - development files.
82
42d161bc
JR
83%description devel -l pl.UTF-8
84Biblioteka kryptograficzna BeeCrypt - pliki dla programistów.
5293cd2f 85
81aa497c 86%package static
87Summary: The BeeCrypt Cryptography Library - static library
6da54b22 88Summary(pl.UTF-8): Biblioteka statyczna BeeCrypt
81aa497c 89Group: Development/Libraries
82780c6a 90Requires: %{name}-devel = %{epoch}:%{version}-%{release}
91407a9e 91
81aa497c 92%description static
93The BeeCrypt Cryptography Library - static library.
91407a9e 94
42d161bc 95%description static -l pl.UTF-8
5293cd2f
JB
96Biblioteka statyczna BeeCrypt.
97
d77df8a9
JB
98%package doc
99Summary: Development documentation for BeeCrypt
6da54b22 100Summary(pl.UTF-8): Dokumentacja programisty dla biblioteki BeeCrypt
d77df8a9
JB
101Group: Documentation
102
103%description doc
104Development documentation for BeeCrypt.
105
42d161bc 106%description doc -l pl.UTF-8
d77df8a9
JB
107Dokumentacja programisty dla biblioteki BeeCrypt.
108
5bdc9e19
JB
109%package java
110Summary: BeeCrypt Java glue library
6da54b22 111Summary(pl.UTF-8): Biblioteka łącząca BeeCrypt z Javą
5bdc9e19
JB
112Group: Libraries
113Requires: %{name} = %{epoch}:%{version}-%{release}
114
115%description java
116BeeCrypt Java glue library.
117
42d161bc
JR
118%description java -l pl.UTF-8
119Biblioteka łącząca BeeCrypt z Javą.
5bdc9e19
JB
120
121%package java-devel
122Summary: Development files for BeeCrypt Java glue library
6da54b22 123Summary(pl.UTF-8): Pliki programistyczne biblioteki łączącej Beecrypt z Javą
5bdc9e19
JB
124Group: Development/Libraries
125Requires: %{name}-devel = %{epoch}:%{version}-%{release}
126Requires: %{name}-java = %{epoch}:%{version}-%{release}
127
128%description java-devel
129Development files for BeeCrypt Java glue library.
130
42d161bc
JR
131%description java-devel -l pl.UTF-8
132Pliki programistyczne biblioteki łączącej Beecrypt z Javą.
5bdc9e19
JB
133
134%package java-static
135Summary: BeeCrypt Java glue static library
6da54b22 136Summary(pl.UTF-8): Statyczna biblioteka łącząca BeeCrypt z Javą
5bdc9e19
JB
137Group: Development/Libraries
138Requires: %{name}-java-devel = %{epoch}:%{version}-%{release}
139
140%description java-static
141BeeCrypt Java glue static library.
142
42d161bc
JR
143%description java-static -l pl.UTF-8
144Statyczna biblioteka łącząca BeeCrypt z Javą.
5bdc9e19 145
6f800bf2
AF
146%package -n python-beecrypt
147Summary: Python interface to BeeCrypt library
6da54b22 148Summary(pl.UTF-8): Pythonowy interfejs do biblioteki BeeCrypt
6f800bf2 149Group: Development/Languages/Python
82780c6a 150Requires: %{name} = %{epoch}:%{version}-%{release}
5bdc9e19 151%pyrequires_eq python-libs
6f800bf2
AF
152
153%description -n python-beecrypt
049b6d8b
ER
154The python-beecrypt package contains a module which permits
155applications written in the Python programming language to use the
156interface supplied by BeeCrypt libraries.
6f800bf2 157
42d161bc
JR
158%description -n python-beecrypt -l pl.UTF-8
159Pakiet python-beecrypt zawiera moduł, który pozwala aplikacjom
160napisanym w Pythonie na używanie interfejsu dostarczanego przez
161bibliotekę BeeCrytp.
6f800bf2 162
91407a9e 163%prep
1b30549c 164%setup -q
63fbc33d 165%patch0 -p1
d97ff880 166%patch1 -p1
c0fd553b 167%patch2 -p1
1b30549c
JB
168
169# --with-cplusplus or building (even empty) *.cxx into libbeecrypt
170# makes it (and thus rpm) depending on libstdc++ which is unacceptable
171%{__perl} -pi -e 's/ cppglue\.cxx$//' Makefile.am
d77df8a9
JB
172# only html docs
173%{__perl} -pi -e 's/^GENERATE_LATEX .*/GENERATE_LATEX = NO/' Doxyfile.in
91407a9e 174
175%build
63fbc33d
AF
176%{__libtoolize}
177%{__aclocal}
178%{__autoconf}
179%{__autoheader}
180%{__automake}
181%configure \
5bdc9e19 182 %{?with_javac:ac_cv_have_gcj=no} \
1b30549c 183 --without-cplusplus \
df503361 184 --with%{!?with_java:out}-java \
d97ff880 185 --with-cpu=%{_target_cpu} \
01129d60 186 %{!?with_static_libs:--enable-static=no} \
442e4fde 187%ifarch %{x8664}
d71f5835
JB
188 --with-arch=x86_64 \
189%else
679c2a8f 190 --with-arch=%{_target_cpu} \
d71f5835 191%endif
4fe951cb 192 --with-pic \
9c971131 193 --with%{!?with_python:out}-python
1b30549c 194%{__make}
91407a9e 195
a927c96f 196%if %{with python}
1b30549c 197%{__make} -C python
a927c96f 198%endif
e7d47e5c 199
7fbed49d 200%if %{with doc}
d48e1138 201doxygen
7fbed49d 202%endif
d48e1138 203
91407a9e 204%install
205rm -rf $RPM_BUILD_ROOT
8db3b7b5 206install -d $RPM_BUILD_ROOT/%{_lib}
81aa497c 207
e7d47e5c
JB
208%{__make} install \
209 DESTDIR=$RPM_BUILD_ROOT
210
a927c96f 211%if %{with python}
e7d47e5c
JB
212%{__make} install -C python \
213 DESTDIR=$RPM_BUILD_ROOT
a927c96f
JK
214%endif
215
8db3b7b5
JB
216mv -f $RPM_BUILD_ROOT%{_libdir}/libbeecrypt.so.*.*.* $RPM_BUILD_ROOT/%{_lib}
217ln -sf /%{_lib}/$(cd $RPM_BUILD_ROOT/%{_lib} ; echo libbeecrypt.so.*.*.*) \
218 $RPM_BUILD_ROOT%{_libdir}/libbeecrypt.so
219
1b30549c
JB
220rm -f $RPM_BUILD_ROOT%{py_sitedir}/*.{la,a}
221
91407a9e 222%clean
81aa497c 223rm -rf $RPM_BUILD_ROOT
224
d97ff880 225%post -p /sbin/ldconfig
81aa497c 226%postun -p /sbin/ldconfig
91407a9e 227
5bdc9e19
JB
228%post java -p /sbin/ldconfig
229%postun java -p /sbin/ldconfig
230
91407a9e 231%files
232%defattr(644,root,root,755)
d97ff880 233%doc AUTHORS BENCHMARKS BUGS CONTRIBUTORS NEWS README
8db3b7b5 234%attr(755,root,root) /%{_lib}/libbeecrypt.so.*.*.*
91407a9e 235
236%files devel
237%defattr(644,root,root,755)
5bdc9e19
JB
238%attr(755,root,root) %{_libdir}/libbeecrypt.so
239%{_libdir}/libbeecrypt.la
240%{_includedir}/beecrypt
81aa497c 241
01129d60 242%if %{with static_libs}
81aa497c 243%files static
244%defattr(644,root,root,755)
5bdc9e19 245%{_libdir}/libbeecrypt.a
01129d60 246%endif
5bdc9e19 247
32db796d 248%if %{with java}
5bdc9e19
JB
249%files java
250%defattr(644,root,root,755)
251%attr(755,root,root) %{_libdir}/libbeecrypt_java.so.*.*.*
252
253%files java-devel
254%defattr(644,root,root,755)
255%attr(755,root,root) %{_libdir}/libbeecrypt_java.so
256%{_libdir}/libbeecrypt_java.la
257
01129d60 258%if %{with static_libs}
5bdc9e19
JB
259%files java-static
260%defattr(644,root,root,755)
261%{_libdir}/libbeecrypt_java.a
262%endif
01129d60 263%endif
6f800bf2 264
7fbed49d 265%if %{with doc}
d77df8a9
JB
266%files doc
267%defattr(644,root,root,755)
a8bc1658 268%doc docs/html
049b6d8b 269%endif
d77df8a9 270
a927c96f 271%if %{with python}
6f800bf2
AF
272%files -n python-beecrypt
273%defattr(644,root,root,755)
274%attr(755,root,root) %{py_sitedir}/*.so
a927c96f 275%endif
This page took 0.13785 seconds and 4 git commands to generate.