]> git.pld-linux.org Git - packages/fftw3.git/blob - fftw3.spec
03d8a39563e3a6dda79093c736a3f3e19871625b
[packages/fftw3.git] / fftw3.spec
1 #
2 # Conditional build:
3 %bcond_without  fftwl   # "long" subpackages
4 %bcond_without  fftwq   # "quad" subpackages
5 %bcond_without  gomp    # OpenMP support
6 #
7 Summary:        Fast Fourier Transform library
8 Summary(pl.UTF-8):      Biblioteka z funkcjami szybkiej transformaty Fouriera
9 Summary(pt_BR.UTF-8):   biblioteca fast fourier transform
10 Name:           fftw3
11 Version:        3.3.2
12 Release:        1
13 License:        GPL v2+
14 Group:          Libraries
15 Source0:        ftp://ftp.fftw.org/pub/fftw/fftw-%{version}.tar.gz
16 # Source0-md5:  6977ee770ed68c85698c7168ffa6e178
17 Patch0:         %{name}-info.patch
18 URL:            http://www.fftw.org/
19 BuildRequires:  autoconf
20 BuildRequires:  automake
21 BuildRequires:  gcc-fortran
22 %ifarch alpha ppc s390 s390x sparc sparcv9
23 %if %{with fftwl}
24 # for 128-bit long double support
25 BuildRequires:  gcc-fortran >= 5:4.1.0-1
26 BuildRequires:  glibc >= 6:2.4-1
27 %endif
28 %endif
29 %if %{with fftwq}
30 BuildRequires:  gcc >= 6:4.6.0
31 BuildRequires:  libquadmath-devel
32 %endif
33 %if %{with gomp}
34 BuildRequires:  gcc >= 6:4.2.0
35 BuildRequires:  libgomp-devel
36 %endif
37 BuildRequires:  libtool
38 BuildRequires:  texinfo
39 Requires:       %{name}-common = %{version}-%{release}
40 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42 %define builds  single double %{?with_fftwl:long-double} %{?with_fftwq:quad-precision}
43
44 %description
45 FFTW is a collection of fast C routines for computing the Discrete
46 Fourier Transform in one or more dimensions. It includes complex,
47 real, and parallel transforms, and can handle arbitrary array sizes
48 efficiently. This RPM package includes the double precision FFTW
49 uniprocessor and threads libraries.
50
51 %description -l pl.UTF-8
52 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
53 transformat Fouriera w jednym lub więcej wymiarach. Zawiera również
54 zespolone, rzeczywiste oraz równoległe transformaty i potrafi wydajnie
55 radzić sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
56 zawiera wersje FFTW o podwójnej precyzji dla architektur
57 jednoprocesorowych oraz z obsługą wątków.
58
59 %description -l pt_BR.UTF-8
60 FFTW é uma coleção de rotinas rápidas em C para computar a Discrete
61 Fourier Transform em uma ou mais dimensões. Incluindo transformações
62 complexas, reais e paralelas, também pode manipular vetores de tamanho
63 arbitrário eficientemente. Esse pacote RPM inclui bibliotecas FFTW com
64 suporte a threads, normal e dupla precisão (Os arquivos de precisão
65 normal tem um prefixo "s").
66
67 %package devel
68 Summary:        Development files for fftw
69 Summary(pl.UTF-8):      Pliki programistyczne do fftw
70 Summary(pt_BR.UTF-8):   Headers e documentação do pacote FFTW
71 Group:          Development/Libraries
72 Requires:       %{name} = %{version}-%{release}
73 Requires:       %{name}-common-devel = %{version}-%{release}
74 %{?with_gomp:Requires:  libgomp-devel}
75
76 %description devel
77 This package contains the files you need to develop programs using the
78 FFTW (fast fourier transform library).
79
80 %description devel -l pl.UTF-8
81 Ten pakiet zawiera pliki potrzebne do tworzenia programów używających
82 biblioteki FFTW (wykonującej szybką transformatę Fouriera).
83
84 %description devel -l pt_BR.UTF-8
85 Este pacote contém documentação e headers adicionais para desenvolver
86 programas usando a FFTW.
87
88 %package static
89 Summary:        Static fftw libraries
90 Summary(pl.UTF-8):      Statyczne biblioteki fftw
91 Summary(pt_BR.UTF-8):   Bibliotecas estáticas do pacote FFTW
92 Group:          Development/Libraries
93 Requires:       %{name}-devel = %{version}-%{release}
94
95 %description static
96 Static fftw libraries.
97
98 %description static -l pl.UTF-8
99 Statyczne biblioteki fftw.
100
101 %description static -l pt_BR.UTF-8
102 Este pacote contém as bibliotecas estáticas do pacote FFTW.
103
104 %package single
105 Summary:        Fast Fourier Transform library - single precision
106 Summary(pl.UTF-8):      Biblioteka z funkcjami szybkiej transformaty Fouriera - pojedynczej precyzji
107 Group:          Libraries
108 Requires:       %{name}-common = %{version}-%{release}
109
110 %description single
111 FFTW is a collection of fast C routines for computing the Discrete
112 Fourier Transform in one or more dimensions. It includes complex,
113 real, and parallel transforms, and can handle arbitrary array sizes
114 efficiently. This RPM package includes the single precision FFTW
115 uniprocessor and threads libraries.
116
117 %description single -l pl.UTF-8
118 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
119 transformat Fouriera w jednym lub więcej wymiarach. Zawiera również
120 zespolone, rzeczywiste oraz równoległe transformaty i potrafi wydajnie
121 radzić sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
122 zawiera wersje FFTW o pojedynczej precyzji dla architektur
123 jednoprocesorowych oraz z obsługą wątków.
124
125 %package single-devel
126 Summary:        Development files for single precision fftw
127 Summary(pl.UTF-8):      Pliki programistyczne do fftw pojedynczej precyzji
128 Group:          Development/Libraries
129 Requires:       %{name}-common-devel = %{version}-%{release}
130 Requires:       %{name}-single = %{version}-%{release}
131 %{?with_gomp:Requires:  libgomp-devel}
132
133 %description single-devel
134 This package contains the files you need to develop programs using the
135 single precision FFTW (fast fourier transform library).
136
137 %description single-devel -l pl.UTF-8
138 Ten pakiet zawiera pliki potrzebne do tworzenia programów używających
139 biblioteki FFTW (wykonującej szybką transformatę Fouriera) pojedynczej
140 precyzji.
141
142 %package single-static
143 Summary:        Static fftw single precision libraries
144 Summary(pl.UTF-8):      Statyczne biblioteki fftw pojedynczej precyzji
145 Group:          Development/Libraries
146 Requires:       %{name}-single-devel = %{version}-%{release}
147
148 %description single-static
149 Static fftw single precision libraries.
150
151 %description single-static -l pl.UTF-8
152 Statyczne biblioteki fftw pojedynczej precyzji.
153
154 %package long
155 Summary:        Fast Fourier Transform library - long double precision
156 Summary(pl.UTF-8):      Biblioteka z funkcjami szybkiej transformaty Fouriera - rozszerzonej precyzji
157 Group:          Libraries
158 Requires:       %{name}-common = %{version}-%{release}
159
160 %description long
161 FFTW is a collection of fast C routines for computing the Discrete
162 Fourier Transform in one or more dimensions. It includes complex,
163 real, and parallel transforms, and can handle arbitrary array sizes
164 efficiently. This RPM package includes the long double precision FFTW
165 uniprocessor and threads libraries.
166
167 %description long -l pl.UTF-8
168 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
169 transformat Fouriera w jednym lub więcej wymiarach. Zawiera również
170 zespolone, rzeczywiste oraz równoległe transformaty i potrafi wydajnie
171 radzić sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
172 zawiera wersje FFTW o rozszerzonej precyzji dla architektur
173 jednoprocesorowych oraz z obsługą wątków.
174
175 %package long-devel
176 Summary:        Development files for long double precision fftw
177 Summary(pl.UTF-8):      Pliki programistyczne do fftw rozszerzonej precyzji
178 Group:          Development/Libraries
179 Requires:       %{name}-common-devel = %{version}-%{release}
180 Requires:       %{name}-long = %{version}-%{release}
181 %{?with_gomp:Requires:  libgomp-devel}
182
183 %description long-devel
184 This package contains the files you need to develop programs using the
185 long double precision FFTW (fast fourier transform library).
186
187 %description long-devel -l pl.UTF-8
188 Ten pakiet zawiera pliki potrzebne do tworzenia programów używających
189 biblioteki FFTW (wykonującej szybką transformatę Fouriera)
190 rozszerzonej precyzji.
191
192 %package long-static
193 Summary:        Static fftw long double precision libraries
194 Summary(pl.UTF-8):      Statyczne biblioteki fftw rozszerzonej precyzji
195 Group:          Development/Libraries
196 Requires:       %{name}-long-devel = %{version}-%{release}
197
198 %description long-static
199 Static fftw long double precision libraries.
200
201 %description long-static -l pl.UTF-8
202 Statyczne biblioteki fftw rozszerzonej precyzji.
203
204 %package quad
205 Summary:        Fast Fourier Transform library - quad precision
206 Summary(pl.UTF-8):      Biblioteka z funkcjami szybkiej transformaty Fouriera - poczwórnej precyzji
207 Group:          Libraries
208 Requires:       %{name}-common = %{version}-%{release}
209
210 %description quad
211 FFTW is a collection of fast C routines for computing the Discrete
212 Fourier Transform in one or more dimensions. It includes complex,
213 real, and parallel transforms, and can handle arbitrary array sizes
214 efficiently. This RPM package includes the quad precision FFTW
215 uniprocessor and threads libraries.
216
217 %description quad -l pl.UTF-8
218 FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych
219 transformat Fouriera w jednym lub więcej wymiarach. Zawiera również
220 zespolone, rzeczywiste oraz równoległe transformaty i potrafi wydajnie
221 radzić sobie z tablicami o dowolnych rozmiarach. Ten pakiet RPM
222 zawiera wersje FFTW o poczwórnej precyzji dla architektur
223 jednoprocesorowych oraz z obsługą wątków.
224
225 %package quad-devel
226 Summary:        Development files for quad precision fftw
227 Summary(pl.UTF-8):      Pliki programistyczne do fftw poczwórnej precyzji
228 Group:          Development/Libraries
229 Requires:       %{name}-common-devel = %{version}-%{release}
230 Requires:       %{name}-quad = %{version}-%{release}
231 %{?with_gomp:Requires:  libgomp-devel}
232 Requires:       libquadmath-devel
233
234 %description quad-devel
235 This package contains the files you need to develop programs using the
236 quad precision FFTW (fast fourier transform library).
237
238 %description quad-devel -l pl.UTF-8
239 Ten pakiet zawiera pliki potrzebne do tworzenia programów używających
240 biblioteki FFTW (wykonującej szybką transformatę Fouriera) poczwórnej
241 precyzji.
242
243 %package quad-static
244 Summary:        Static fftw quad precision libraries
245 Summary(pl.UTF-8):      Statyczne biblioteki fftw poczwórnej precyzji
246 Group:          Development/Libraries
247 Requires:       %{name}-quad-devel = %{version}-%{release}
248
249 %description quad-static
250 Static fftw quad precision libraries.
251
252 %description quad-static -l pl.UTF-8
253 Statyczne biblioteki fftw poczwórnej precyzji.
254
255 %package common
256 Summary:        Files common for all versions of fftw libraries
257 Summary(pl.UTF-8):      Pliki wspólne dla wszystkich wersji bibliotek fftw
258 Group:          Libraries
259
260 %description common
261 Files common for all versions of fftw libraries (basic documentation,
262 fftw-wisdom-to-conf utility).
263
264 %description common -l pl.UTF-8
265 Pliki wspólne dla wszystkich wersji bibliotek fftw (podstawowa
266 dokumentacja, narzędzie fftw-wisdom-to-conf).
267
268 %package common-devel
269 Summary:        Development files common for all versions of fftw libraries
270 Summary(pl.UTF-8):      Pliki programistyczne wspólne dla wszystkich wersji bibliotek fftw
271 Group:          Development/Libraries
272 Requires:       %{name}-common = %{version}-%{release}
273
274 %description common-devel
275 Development files common for all versions of fftw libraries (header
276 files, development documentation).
277
278 %description common-devel -l pl.UTF-8
279 Pliki programistyczne wspólne dla wszystkich wersji bibliotek fftw
280 (pliki nagłówkowe, dokumentacja programisty).
281
282 %prep
283 %setup -q -n fftw-%{version}
284 %patch0 -p1
285
286 %build
287 %{__libtoolize}
288 %{__aclocal} -I m4
289 %{__autoconf}
290 %{__automake}
291
292 # MMX/SSE/etc. seem to be safe because of runtime CPU detection
293 for ver in %{builds}; do
294         OPTS=""
295         # k7,SSE,3dnow,altivec only for single
296         if [ "$ver" = "single" ]; then
297 %ifarch i686 pentium3 pentium4
298                 OPTS="--enable-sse"
299 %endif
300 %ifarch athlon
301                 OPTS="--enable-sse" # no "--enable-k7" - conflicts with shared, SEGV on athlons
302 %endif
303 %ifarch ppc
304                 OPTS="--enable-altivec"
305 %endif
306 %ifnarch i686 k6 athlon ppc
307                 :       # keep sh happy about syntax
308 %endif
309         fi
310 %ifarch i686 pentium4
311         # SSE2 only for double
312         if [ "$ver" = "double" -o "$ver" = "single" ]; then
313                 OPTS="--enable-sse2 --enable-avx"
314         fi
315 %endif
316 install -d build-${ver}
317 cd build-${ver}
318 ../%configure \
319         --enable-openmp \
320         --enable-shared \
321         --enable-threads \
322         --enable-$ver \
323         $OPTS \
324         --%{!?debug:dis}%{?debug:en}able-debug
325
326 %{__make}
327 cd ..
328 done
329
330 %install
331 rm -rf $RPM_BUILD_ROOT
332 install -d $RPM_BUILD_ROOT%{_sysconfdir}/fftw
333
334 for b in %{builds} ; do
335         %{__make} install -C build-${b} \
336                 DESTDIR=$RPM_BUILD_ROOT
337 done
338
339 %clean
340 rm -rf $RPM_BUILD_ROOT
341
342 %post   -p /sbin/ldconfig
343 %postun -p /sbin/ldconfig
344
345 %post   single -p /sbin/ldconfig
346 %postun single -p /sbin/ldconfig
347
348 %post   long -p /sbin/ldconfig
349 %postun long -p /sbin/ldconfig
350
351 %post   common-devel -p /sbin/postshell
352 -/usr/sbin/fix-info-dir -c %{_infodir}
353
354 %postun common-devel -p /sbin/postshell
355 -/usr/sbin/fix-info-dir -c %{_infodir}
356
357 %files
358 %defattr(644,root,root,755)
359 %attr(755,root,root) %{_bindir}/fftw-wisdom
360 %attr(755,root,root) %{_libdir}/libfftw3.so.*.*.*
361 %attr(755,root,root) %ghost %{_libdir}/libfftw3.so.3
362 %attr(755,root,root) %{_libdir}/libfftw3_threads.so.*.*.*
363 %attr(755,root,root) %ghost %{_libdir}/libfftw3_threads.so.3
364 %if %{with gomp}
365 %attr(755,root,root) %{_libdir}/libfftw3_omp.so.*.*.*
366 %attr(755,root,root) %ghost %{_libdir}/libfftw3_omp.so.3
367 %endif
368 %{_mandir}/man1/fftw-wisdom.1*
369
370 %files devel
371 %defattr(644,root,root,755)
372 %attr(755,root,root) %{_libdir}/libfftw3.so
373 %attr(755,root,root) %{_libdir}/libfftw3_threads.so
374 %{_libdir}/libfftw3.la
375 %{_libdir}/libfftw3_threads.la
376 %if %{with gomp}
377 %attr(755,root,root) %{_libdir}/libfftw3_omp.so
378 %{_libdir}/libfftw3_omp.la
379 %endif
380 %{_pkgconfigdir}/fftw3.pc
381
382 %files static
383 %defattr(644,root,root,755)
384 %{_libdir}/libfftw3.a
385 %{_libdir}/libfftw3_threads.a
386 %if %{with gomp}
387 %{_libdir}/libfftw3_omp.a
388 %endif
389
390 %files single
391 %defattr(644,root,root,755)
392 %attr(755,root,root) %{_bindir}/fftwf-wisdom
393 %attr(755,root,root) %{_libdir}/libfftw3f.so.*.*.*
394 %attr(755,root,root) %ghost %{_libdir}/libfftw3f.so.3
395 %attr(755,root,root) %{_libdir}/libfftw3f_threads.so.*.*.*
396 %attr(755,root,root) %ghost %{_libdir}/libfftw3f_threads.so.3
397 %if %{with gomp}
398 %attr(755,root,root) %{_libdir}/libfftw3f_omp.so.*.*.*
399 %attr(755,root,root) %ghost %{_libdir}/libfftw3f_omp.so.3
400 %endif
401 %{_mandir}/man1/fftwf-wisdom.1*
402
403 %files single-devel
404 %defattr(644,root,root,755)
405 %attr(755,root,root) %{_libdir}/libfftw3f.so
406 %attr(755,root,root) %{_libdir}/libfftw3f_threads.so
407 %{_libdir}/libfftw3f.la
408 %{_libdir}/libfftw3f_threads.la
409 %if %{with gomp}
410 %attr(755,root,root) %{_libdir}/libfftw3f_omp.so
411 %{_libdir}/libfftw3f_omp.la
412 %endif
413 %{_pkgconfigdir}/fftw3f.pc
414
415 %files single-static
416 %defattr(644,root,root,755)
417 %{_libdir}/libfftw3f.a
418 %{_libdir}/libfftw3f_threads.a
419 %if %{with gomp}
420 %{_libdir}/libfftw3f_omp.a
421 %endif
422
423 %if %{with fftwl}
424 %files long
425 %defattr(644,root,root,755)
426 %attr(755,root,root) %{_bindir}/fftwl-wisdom
427 %attr(755,root,root) %{_libdir}/libfftw3l.so.*.*.*
428 %attr(755,root,root) %ghost %{_libdir}/libfftw3l.so.3
429 %attr(755,root,root) %{_libdir}/libfftw3l_threads.so.*.*.*
430 %attr(755,root,root) %ghost %{_libdir}/libfftw3l_threads.so.3
431 %if %{with gomp}
432 %attr(755,root,root) %{_libdir}/libfftw3l_omp.so.*.*.*
433 %attr(755,root,root) %ghost %{_libdir}/libfftw3l_omp.so.3
434 %endif
435 %{_mandir}/man1/fftwl-wisdom.1*
436
437 %files long-devel
438 %defattr(644,root,root,755)
439 %attr(755,root,root) %{_libdir}/libfftw3l.so
440 %attr(755,root,root) %{_libdir}/libfftw3l_threads.so
441 %{_libdir}/libfftw3l.la
442 %{_libdir}/libfftw3l_threads.la
443 %if %{with gomp}
444 %attr(755,root,root) %{_libdir}/libfftw3l_omp.so
445 %{_libdir}/libfftw3l_omp.la
446 %endif
447 %{_includedir}/fftw3l.f03
448 %{_pkgconfigdir}/fftw3l.pc
449
450 %files long-static
451 %defattr(644,root,root,755)
452 %{_libdir}/libfftw3l.a
453 %{_libdir}/libfftw3l_threads.a
454 %if %{with gomp}
455 %{_libdir}/libfftw3l_omp.a
456 %endif
457 %endif
458
459 %if %{with fftwq}
460 %files quad
461 %defattr(644,root,root,755)
462 %attr(755,root,root) %{_bindir}/fftwq-wisdom
463 %attr(755,root,root) %{_libdir}/libfftw3q.so.*.*.*
464 %attr(755,root,root) %ghost %{_libdir}/libfftw3q.so.3
465 %attr(755,root,root) %{_libdir}/libfftw3q_threads.so.*.*.*
466 %attr(755,root,root) %ghost %{_libdir}/libfftw3q_threads.so.3
467 %if %{with gomp}
468 %attr(755,root,root) %{_libdir}/libfftw3q_omp.so.*.*.*
469 %attr(755,root,root) %ghost %{_libdir}/libfftw3q_omp.so.3
470 %endif
471 %{_mandir}/man1/fftwq-wisdom.1*
472
473 %files quad-devel
474 %defattr(644,root,root,755)
475 %attr(755,root,root) %{_libdir}/libfftw3q.so
476 %attr(755,root,root) %{_libdir}/libfftw3q_threads.so
477 %{_libdir}/libfftw3q.la
478 %{_libdir}/libfftw3q_threads.la
479 %if %{with gomp}
480 %attr(755,root,root) %{_libdir}/libfftw3q_omp.so
481 %{_libdir}/libfftw3q_omp.la
482 %endif
483 %{_includedir}/fftw3q.f03
484 %{_pkgconfigdir}/fftw3q.pc
485
486 %files quad-static
487 %defattr(644,root,root,755)
488 %{_libdir}/libfftw3q.a
489 %{_libdir}/libfftw3q_threads.a
490 %if %{with gomp}
491 %{_libdir}/libfftw3q_omp.a
492 %endif
493 %endif
494
495 %files common
496 %defattr(644,root,root,755)
497 %doc AUTHORS COPYRIGHT ChangeLog NEWS README TODO
498 %dir %{_sysconfdir}/fftw
499 %attr(755,root,root) %{_bindir}/fftw-wisdom-to-conf
500 %{_mandir}/man1/fftw-wisdom-to-conf.1*
501
502 %files common-devel
503 %defattr(644,root,root,755)
504 %doc doc/html doc/FAQ/fftw-faq.html
505 %{_includedir}/fftw3.f
506 %{_includedir}/fftw3.f03
507 %{_includedir}/fftw3.h
508 %{_infodir}/fftw3.info*
This page took 0.063653 seconds and 2 git commands to generate.