]> git.pld-linux.org Git - packages/fftw3.git/blob - fftw3.spec
1f50da5e7679664350fe2d6bad4c96cd4ec04206
[packages/fftw3.git] / fftw3.spec
1 #
2 # Conditional build:
3 %bcond_without  fftwl   # don't build "long" subpackages
4 #
5 Summary:        Fast Fourier Transform library
6 Summary(pl):    Biblioteka z funkcjami szybkiej transformaty Fouriera
7 Summary(pt_BR): biblioteca fast fourier transform
8 Name:           fftw3
9 Version:        3.1
10 Release:        3
11 License:        GPL
12 Group:          Libraries
13 Source0:        ftp://ftp.fftw.org/pub/fftw/fftw-%{version}.tar.gz
14 # Source0-md5:  911515569a8abdc7dbb207d53f34e60b
15 Patch0:         %{name}-info.patch
16 Patch1:         %{name}-link.patch
17 Patch2:         %{name}-ac_simd.patch
18 URL:            http://www.fftw.org/
19 BuildRequires:  autoconf
20 BuildRequires:  automake
21 %ifarch alpha ppc s390 s390x sparc sparcv9
22 %if %{with fftwl}
23 # for 128-bit long double support
24 BuildRequires:  gcc-fortran >= 5:4.1.0-1
25 BuildRequires:  glibc >= 6:2.4-1
26 %endif
27 %endif
28 BuildRequires:  libtool
29 BuildRequires:  texinfo
30 Requires:       %{name}-common = %{version}-%{release}
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %description
34 FFTW is a collection of fast C routines for computing the Discrete
35 Fourier Transform in one or more dimensions. It includes complex,
36 real, and parallel transforms, and can handle arbitrary array sizes
37 efficiently. This RPM package includes the double precision FFTW
38 uniprocessor and threads libraries.
39
40 %description -l pl
41 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
42 transformat Fouriera w jednym lub wiêcej wymiarach. Zawiera równie¿
43 zespolone, rzeczywiste oraz równoleg³e transformaty i potrafi wydajnie
44 radziæ sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
45 zawiera wersje FFTW o podwójnej precyzji dla architektur
46 jednoprocesorowych oraz z obs³ug± w±tków.
47
48 %description -l pt_BR
49 FFTW é uma coleção de rotinas rápidas em C para computar a Discrete
50 Fourier Transform em uma ou mais dimensões. Incluindo transformações
51 complexas, reais e paralelas, também pode manipular vetores de tamanho
52 arbitrário eficientemente. Esse pacote RPM inclui bibliotecas FFTW com
53 suporte a threads, normal e dupla precisão (Os arquivos de precisão
54 normal tem um prefixo "s").
55
56 %package devel
57 Summary:        Development files for fftw
58 Summary(pl):    Pliki programistyczne do fftw
59 Summary(pt_BR): Headers e documentação do pacote FFTW
60 Group:          Development/Libraries
61 Requires:       %{name} = %{version}-%{release}
62 Requires:       %{name}-common-devel = %{version}-%{release}
63
64 %description devel
65 This package contains the files you need to develop programs using the
66 FFTW (fast fourier transform library).
67
68 %description devel -l pl
69 Ten pakiet zawiera pliki potrzebne do tworzenia programów u¿ywaj±cych
70 biblioteki FFTW (wykonuj±cej szybk± transformatê Fouriera).
71
72 %description devel -l pt_BR
73 Este pacote contém documentação e headers adicionais para desenvolver
74 programas usando a FFTW.
75
76 %package static
77 Summary:        Static fftw libraries
78 Summary(pl):    Statyczne biblioteki fftw
79 Summary(pt_BR): Bibliotecas estáticas do pacote FFTW
80 Group:          Development/Libraries
81 Requires:       %{name}-devel = %{version}-%{release}
82
83 %description static
84 Static fftw libraries.
85
86 %description static -l pl
87 Statyczne biblioteki fftw.
88
89 %description static -l pt_BR
90 Este pacote contém as bibliotecas estáticas do pacote FFTW.
91
92 %package single
93 Summary:        Fast Fourier Transform library - single precision
94 Summary(pl):    Biblioteka z funkcjami szybkiej transformaty Fouriera - pojedynczej precyzji
95 Group:          Libraries
96 Requires:       %{name}-common = %{version}-%{release}
97
98 %description single
99 FFTW is a collection of fast C routines for computing the Discrete
100 Fourier Transform in one or more dimensions. It includes complex,
101 real, and parallel transforms, and can handle arbitrary array sizes
102 efficiently. This RPM package includes the single precision FFTW
103 uniprocessor and threads libraries.
104
105 %description single -l pl
106 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
107 transformat Fouriera w jednym lub wiêcej wymiarach. Zawiera równie¿
108 zespolone, rzeczywiste oraz równoleg³e transformaty i potrafi wydajnie
109 radziæ sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
110 zawiera wersje FFTW o pojedynczej precyzji dla architektur
111 jednoprocesorowych oraz z obs³ug± w±tków.
112
113 %package single-devel
114 Summary:        Development files for single precision fftw
115 Summary(pl):    Pliki programistyczne do fftw pojedynczej precyzji
116 Group:          Development/Libraries
117 Requires:       %{name}-common-devel = %{version}-%{release}
118 Requires:       %{name}-single = %{version}-%{release}
119
120 %description single-devel
121 This package contains the files you need to develop programs using the
122 single precision FFTW (fast fourier transform library).
123
124 %description single-devel -l pl
125 Ten pakiet zawiera pliki potrzebne do tworzenia programów u¿ywaj±cych
126 biblioteki FFTW pojedynczej precyzji (wykonuj±cej szybk± transformatê
127 Fouriera).
128
129 %package single-static
130 Summary:        Static fftw single precision libraries
131 Summary(pl):    Statyczne biblioteki fftw pojedynczej precyzji
132 Group:          Development/Libraries
133 Requires:       %{name}-single-devel = %{version}-%{release}
134
135 %description single-static
136 Static fftw single precision libraries.
137
138 %description single-static -l pl
139 Statyczne biblioteki fftw pojedynczej precyzji.
140
141 %package long
142 Summary:        Fast Fourier Transform library - long double precision
143 Summary(pl):    Biblioteka z funkcjami szybkiej transformaty Fouriera - rozszerzonej precyzji
144 Group:          Libraries
145 Requires:       %{name}-common = %{version}-%{release}
146
147 %description long
148 FFTW is a collection of fast C routines for computing the Discrete
149 Fourier Transform in one or more dimensions. It includes complex,
150 real, and parallel transforms, and can handle arbitrary array sizes
151 efficiently. This RPM package includes the long double precision FFTW
152 uniprocessor and threads libraries.
153
154 %description long -l pl
155 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
156 transformat Fouriera w jednym lub wiêcej wymiarach. Zawiera równie¿
157 zespolone, rzeczywiste oraz równoleg³e transformaty i potrafi wydajnie
158 radziæ sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
159 zawiera wersje FFTW o rozszerzonej precyzji dla architektur
160 jednoprocesorowych oraz z obs³ug± w±tków.
161
162 %package long-devel
163 Summary:        Development files for long double precision fftw
164 Summary(pl):    Pliki programistyczne do fftw rozszerzonej precyzji
165 Group:          Development/Libraries
166 Requires:       %{name}-common-devel = %{version}-%{release}
167 Requires:       %{name}-long = %{version}-%{release}
168
169 %description long-devel
170 This package contains the files you need to develop programs using the
171 long double precision FFTW (fast fourier transform library).
172
173 %description long-devel -l pl
174 Ten pakiet zawiera pliki potrzebne do tworzenia programów u¿ywaj±cych
175 biblioteki FFTW rozszerzonej precyzji (wykonuj±cej szybk± transformatê
176 Fouriera).
177
178 %package long-static
179 Summary:        Static fftw long double precision libraries
180 Summary(pl):    Statyczne biblioteki fftw rozszerzonej precyzji
181 Group:          Development/Libraries
182 Requires:       %{name}-long-devel = %{version}-%{release}
183
184 %description long-static
185 Static fftw long double precision libraries.
186
187 %description long-static -l pl
188 Statyczne biblioteki fftw rozszerzonej precyzji.
189
190 %package common
191 Summary:        Files common for all versions of fftw libraries
192 Summary(pl):    Pliki wspólne dla wszystkich wersji bibliotek fftw
193 Group:          Libraries
194
195 %description common
196 Files common for all versions of fftw libraries (basic documentation,
197 fftw-wisdom-to-conf utility).
198
199 %description common -l pl
200 Pliki wspólne dla wszystkich wersji bibliotek fftw (podstawowa
201 dokumentacja, narzêdzie fftw-wisdom-to-conf).
202
203 %package common-devel
204 Summary:        Development files common for all versions of fftw libraries
205 Summary(pl):    Pliki programistyczne wspólne dla wszystkich wersji bibliotek fftw
206 Group:          Development/Libraries
207 Requires:       %{name}-common = %{version}-%{release}
208
209 %description common-devel
210 Development files common for all versions of fftw libraries (header
211 files, development documentation).
212
213 %description common-devel -l pl
214 Pliki programistyczne wspólne dla wszystkich wersji bibliotek fftw
215 (pliki nag³ówkowe, dokumentacja programisty).
216
217 %prep
218 %setup -q -n fftw-%{version}
219 %patch0 -p1
220 %patch1 -p1
221 %patch2 -p1
222
223 %build
224 %{__libtoolize}
225 %{__aclocal} -I m4
226 %{__autoconf}
227 %{__automake}
228
229 # prepare three trees (for single, double, long-double precision)
230 rm -rf single double long-double
231 echo * > files.list
232 install -d single long-double
233 cp -a `cat files.list` single
234 cp -a `cat files.list` long-double
235 ln -sf . double
236
237 # MMX/SSE/etc. seem to be safe because of runtime CPU detection
238 for ver in single double %{?with_fftwl:long-double}; do
239         OPTS=""
240         # k7,SSE,3dnow,altivec only for single
241         if [ "$ver" = "single" ]; then
242 %ifarch i686
243                 OPTS="--enable-sse"
244 %endif
245 %ifarch athlon
246                 OPTS="--enable-sse" # no "--enable-k7" - conflicts with shared, SEGV on athlons
247 %endif
248 %ifarch ppc
249                 OPTS="--enable-altivec"
250 %endif
251 %ifnarch i586 i686 k6 athlon ppc
252                 :       # keep sh happy about syntax
253 %endif
254         fi
255 %ifarch i686
256         # SSE2 only for double
257         if [ "$ver" = "double" ]; then
258                 OPTS="--enable-sse2"
259         fi
260 %endif
261 cd $ver
262 %configure \
263         --enable-shared \
264         --enable-threads \
265         --enable-$ver \
266         $OPTS \
267         --%{!?debug:dis}%{?debug:en}able-debug
268
269 %{__make}
270
271 cd ..
272 done
273
274 %install
275 rm -rf $RPM_BUILD_ROOT
276
277 %{__make} install \
278         DESTDIR=$RPM_BUILD_ROOT
279
280 %{__make} install -C single \
281         DESTDIR=$RPM_BUILD_ROOT
282
283 %if %{with fftwl}
284 %{__make} install -C long-double \
285         DESTDIR=$RPM_BUILD_ROOT
286 %endif
287
288 %clean
289 rm -rf $RPM_BUILD_ROOT
290
291 %post   -p /sbin/ldconfig
292 %postun -p /sbin/ldconfig
293
294 %post common-devel
295 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
296
297 %postun common-devel
298 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
299
300 %files
301 %defattr(644,root,root,755)
302 %attr(755,root,root) %{_bindir}/fftw-wisdom
303 %attr(755,root,root) %{_libdir}/libfftw3.so.*.*.*
304 %attr(755,root,root) %{_libdir}/libfftw3_threads.so.*.*.*
305 %{_mandir}/man1/fftw-wisdom.1*
306
307 %files devel
308 %defattr(644,root,root,755)
309 %attr(755,root,root) %{_libdir}/libfftw3.so
310 %attr(755,root,root) %{_libdir}/libfftw3_threads.so
311 %{_libdir}/libfftw3.la
312 %{_libdir}/libfftw3_threads.la
313 %{_pkgconfigdir}/fftw3.pc
314
315 %files static
316 %defattr(644,root,root,755)
317 %{_libdir}/libfftw3.a
318 %{_libdir}/libfftw3_threads.a
319
320 %files single
321 %defattr(644,root,root,755)
322 %attr(755,root,root) %{_bindir}/fftwf-wisdom
323 %attr(755,root,root) %{_libdir}/libfftw3f.so.*.*.*
324 %attr(755,root,root) %{_libdir}/libfftw3f_threads.so.*.*.*
325 %{_mandir}/man1/fftwf-wisdom.1*
326
327 %files single-devel
328 %defattr(644,root,root,755)
329 %attr(755,root,root) %{_libdir}/libfftw3f.so
330 %attr(755,root,root) %{_libdir}/libfftw3f_threads.so
331 %{_libdir}/libfftw3f.la
332 %{_libdir}/libfftw3f_threads.la
333 %{_pkgconfigdir}/fftw3f.pc
334
335 %files single-static
336 %defattr(644,root,root,755)
337 %{_libdir}/libfftw3f.a
338 %{_libdir}/libfftw3f_threads.a
339
340 %if %{with fftwl}
341 %files long
342 %defattr(644,root,root,755)
343 %attr(755,root,root) %{_bindir}/fftwl-wisdom
344 %attr(755,root,root) %{_libdir}/libfftw3l.so.*.*.*
345 %attr(755,root,root) %{_libdir}/libfftw3l_threads.so.*.*.*
346 %{_mandir}/man1/fftwl-wisdom.1*
347
348 %files long-devel
349 %defattr(644,root,root,755)
350 %attr(755,root,root) %{_libdir}/libfftw3l.so
351 %attr(755,root,root) %{_libdir}/libfftw3l_threads.so
352 %{_libdir}/libfftw3l.la
353 %{_libdir}/libfftw3l_threads.la
354 %{_pkgconfigdir}/fftw3l.pc
355
356 %files long-static
357 %defattr(644,root,root,755)
358 %{_libdir}/libfftw3l.a
359 %{_libdir}/libfftw3l_threads.a
360 %endif
361
362 %files common
363 %defattr(644,root,root,755)
364 %doc AUTHORS COPYRIGHT ChangeLog NEWS README TODO
365 %attr(755,root,root) %{_bindir}/fftw-wisdom-to-conf
366 %{_mandir}/man1/fftw-wisdom-to-conf.1*
367
368 %files common-devel
369 %defattr(644,root,root,755)
370 %doc doc/html doc/FAQ/fftw-faq.html
371 %{_includedir}/fftw3.*
372 %{_infodir}/fftw3.info*
This page took 0.041644 seconds and 2 git commands to generate.