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