]>
Commit | Line | Data |
---|---|---|
7de82846 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without fftwl # don't build "long" subpackages | |
4 | # | |
f2b41f11 | 5 | Summary: Fast Fourier Transform library |
b8f7299a ER |
6 | Summary(pl.UTF-8): Biblioteka z funkcjami szybkiej transformaty Fouriera |
7 | Summary(pt_BR.UTF-8): biblioteca fast fourier transform | |
8dd64783 | 8 | Name: fftw3 |
a46795d7 JB |
9 | Version: 3.2.2 |
10 | Release: 1 | |
2e6b9bdb | 11 | License: GPL v2+ |
8dd64783 JB |
12 | Group: Libraries |
13 | Source0: ftp://ftp.fftw.org/pub/fftw/fftw-%{version}.tar.gz | |
a46795d7 | 14 | # Source0-md5: b616e5c91218cc778b5aa735fefb61ae |
8dd64783 | 15 | Patch0: %{name}-info.patch |
f2b41f11 | 16 | Patch1: %{name}-link.patch |
b1df447f | 17 | Patch2: %{name}-ac_simd.patch |
8dd64783 JB |
18 | URL: http://www.fftw.org/ |
19 | BuildRequires: autoconf | |
20 | BuildRequires: automake | |
7de82846 JB |
21 | %ifarch alpha ppc s390 s390x sparc sparcv9 |
22 | %if %{with fftwl} | |
335eed51 PS |
23 | # for 128-bit long double support |
24 | BuildRequires: gcc-fortran >= 5:4.1.0-1 | |
25 | BuildRequires: glibc >= 6:2.4-1 | |
7de82846 JB |
26 | %endif |
27 | %endif | |
8dd64783 | 28 | BuildRequires: libtool |
bf578b06 | 29 | BuildRequires: texinfo |
f24101b7 | 30 | Requires: %{name}-common = %{version}-%{release} |
8dd64783 JB |
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 | ||
b4a355b4 | 40 | %description -l pl.UTF-8 |
8dd64783 | 41 | FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych |
b4a355b4 JR |
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.UTF-8 | |
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 | |
8dd64783 JB |
54 | normal tem um prefixo "s"). |
55 | ||
56 | %package devel | |
f2b41f11 | 57 | Summary: Development files for fftw |
b8f7299a ER |
58 | Summary(pl.UTF-8): Pliki programistyczne do fftw |
59 | Summary(pt_BR.UTF-8): Headers e documentação do pacote FFTW | |
8dd64783 | 60 | Group: Development/Libraries |
f24101b7 JB |
61 | Requires: %{name} = %{version}-%{release} |
62 | Requires: %{name}-common-devel = %{version}-%{release} | |
8dd64783 JB |
63 | |
64 | %description devel | |
f2b41f11 JB |
65 | This package contains the files you need to develop programs using the |
66 | FFTW (fast fourier transform library). | |
8dd64783 | 67 | |
b4a355b4 JR |
68 | %description devel -l pl.UTF-8 |
69 | Ten pakiet zawiera pliki potrzebne do tworzenia programów używających | |
70 | biblioteki FFTW (wykonującej szybką transformatę Fouriera). | |
8dd64783 | 71 | |
b4a355b4 JR |
72 | %description devel -l pt_BR.UTF-8 |
73 | Este pacote contém documentação e headers adicionais para desenvolver | |
0210e72d | 74 | programas usando a FFTW. |
8dd64783 JB |
75 | |
76 | %package static | |
77 | Summary: Static fftw libraries | |
b8f7299a ER |
78 | Summary(pl.UTF-8): Statyczne biblioteki fftw |
79 | Summary(pt_BR.UTF-8): Bibliotecas estáticas do pacote FFTW | |
8dd64783 | 80 | Group: Development/Libraries |
f24101b7 | 81 | Requires: %{name}-devel = %{version}-%{release} |
8dd64783 JB |
82 | |
83 | %description static | |
84 | Static fftw libraries. | |
85 | ||
b4a355b4 | 86 | %description static -l pl.UTF-8 |
8dd64783 JB |
87 | Statyczne biblioteki fftw. |
88 | ||
b4a355b4 JR |
89 | %description static -l pt_BR.UTF-8 |
90 | Este pacote contém as bibliotecas estáticas do pacote FFTW. | |
8dd64783 | 91 | |
f2b41f11 JB |
92 | %package single |
93 | Summary: Fast Fourier Transform library - single precision | |
b8f7299a | 94 | Summary(pl.UTF-8): Biblioteka z funkcjami szybkiej transformaty Fouriera - pojedynczej precyzji |
f2b41f11 | 95 | Group: Libraries |
f24101b7 | 96 | Requires: %{name}-common = %{version}-%{release} |
f2b41f11 JB |
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 | ||
b4a355b4 | 105 | %description single -l pl.UTF-8 |
f2b41f11 | 106 | FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych |
b4a355b4 JR |
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 | |
f2b41f11 | 110 | zawiera wersje FFTW o pojedynczej precyzji dla architektur |
b4a355b4 | 111 | jednoprocesorowych oraz z obsługą wątków. |
f2b41f11 JB |
112 | |
113 | %package single-devel | |
114 | Summary: Development files for single precision fftw | |
b8f7299a | 115 | Summary(pl.UTF-8): Pliki programistyczne do fftw pojedynczej precyzji |
f2b41f11 | 116 | Group: Development/Libraries |
f24101b7 JB |
117 | Requires: %{name}-common-devel = %{version}-%{release} |
118 | Requires: %{name}-single = %{version}-%{release} | |
f2b41f11 JB |
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 | ||
b4a355b4 JR |
124 | %description single-devel -l pl.UTF-8 |
125 | Ten pakiet zawiera pliki potrzebne do tworzenia programów używających | |
126 | biblioteki FFTW pojedynczej precyzji (wykonującej szybką transformatę | |
f2b41f11 JB |
127 | Fouriera). |
128 | ||
129 | %package single-static | |
130 | Summary: Static fftw single precision libraries | |
b8f7299a | 131 | Summary(pl.UTF-8): Statyczne biblioteki fftw pojedynczej precyzji |
f2b41f11 | 132 | Group: Development/Libraries |
f24101b7 | 133 | Requires: %{name}-single-devel = %{version}-%{release} |
f2b41f11 JB |
134 | |
135 | %description single-static | |
136 | Static fftw single precision libraries. | |
137 | ||
b4a355b4 | 138 | %description single-static -l pl.UTF-8 |
f2b41f11 JB |
139 | Statyczne biblioteki fftw pojedynczej precyzji. |
140 | ||
141 | %package long | |
142 | Summary: Fast Fourier Transform library - long double precision | |
b8f7299a | 143 | Summary(pl.UTF-8): Biblioteka z funkcjami szybkiej transformaty Fouriera - rozszerzonej precyzji |
f2b41f11 | 144 | Group: Libraries |
f24101b7 | 145 | Requires: %{name}-common = %{version}-%{release} |
f2b41f11 JB |
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 | ||
b4a355b4 | 154 | %description long -l pl.UTF-8 |
f2b41f11 | 155 | FFTW jest zbiorem szybkich funkcji C do obliczania dyskretnych |
b4a355b4 JR |
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 | |
f2b41f11 | 159 | zawiera wersje FFTW o rozszerzonej precyzji dla architektur |
b4a355b4 | 160 | jednoprocesorowych oraz z obsługą wątków. |
f2b41f11 JB |
161 | |
162 | %package long-devel | |
163 | Summary: Development files for long double precision fftw | |
b8f7299a | 164 | Summary(pl.UTF-8): Pliki programistyczne do fftw rozszerzonej precyzji |
f2b41f11 | 165 | Group: Development/Libraries |
f24101b7 JB |
166 | Requires: %{name}-common-devel = %{version}-%{release} |
167 | Requires: %{name}-long = %{version}-%{release} | |
f2b41f11 JB |
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 | ||
b4a355b4 JR |
173 | %description long-devel -l pl.UTF-8 |
174 | Ten pakiet zawiera pliki potrzebne do tworzenia programów używających | |
175 | biblioteki FFTW rozszerzonej precyzji (wykonującej szybką transformatę | |
f2b41f11 JB |
176 | Fouriera). |
177 | ||
178 | %package long-static | |
179 | Summary: Static fftw long double precision libraries | |
b8f7299a | 180 | Summary(pl.UTF-8): Statyczne biblioteki fftw rozszerzonej precyzji |
f2b41f11 | 181 | Group: Development/Libraries |
f24101b7 | 182 | Requires: %{name}-long-devel = %{version}-%{release} |
f2b41f11 JB |
183 | |
184 | %description long-static | |
185 | Static fftw long double precision libraries. | |
186 | ||
b4a355b4 | 187 | %description long-static -l pl.UTF-8 |
f2b41f11 JB |
188 | Statyczne biblioteki fftw rozszerzonej precyzji. |
189 | ||
190 | %package common | |
191 | Summary: Files common for all versions of fftw libraries | |
b8f7299a | 192 | Summary(pl.UTF-8): Pliki wspólne dla wszystkich wersji bibliotek fftw |
f2b41f11 JB |
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 | ||
b4a355b4 JR |
199 | %description common -l pl.UTF-8 |
200 | Pliki wspólne dla wszystkich wersji bibliotek fftw (podstawowa | |
201 | dokumentacja, narzędzie fftw-wisdom-to-conf). | |
f2b41f11 JB |
202 | |
203 | %package common-devel | |
204 | Summary: Development files common for all versions of fftw libraries | |
b8f7299a | 205 | Summary(pl.UTF-8): Pliki programistyczne wspólne dla wszystkich wersji bibliotek fftw |
f2b41f11 | 206 | Group: Development/Libraries |
f24101b7 | 207 | Requires: %{name}-common = %{version}-%{release} |
f2b41f11 JB |
208 | |
209 | %description common-devel | |
210 | Development files common for all versions of fftw libraries (header | |
211 | files, development documentation). | |
212 | ||
b4a355b4 JR |
213 | %description common-devel -l pl.UTF-8 |
214 | Pliki programistyczne wspólne dla wszystkich wersji bibliotek fftw | |
215 | (pliki nagłówkowe, dokumentacja programisty). | |
f2b41f11 | 216 | |
8dd64783 JB |
217 | %prep |
218 | %setup -q -n fftw-%{version} | |
f2b41f11 JB |
219 | %patch0 -p1 |
220 | %patch1 -p1 | |
b1df447f | 221 | %patch2 -p1 |
8dd64783 JB |
222 | |
223 | %build | |
224 | %{__libtoolize} | |
376d0cb4 | 225 | %{__aclocal} -I m4 |
8dd64783 JB |
226 | %{__autoconf} |
227 | %{__automake} | |
f2b41f11 | 228 | |
f2b41f11 | 229 | # MMX/SSE/etc. seem to be safe because of runtime CPU detection |
7de82846 | 230 | for ver in single double %{?with_fftwl:long-double}; do |
8dd64783 JB |
231 | OPTS="" |
232 | # k7,SSE,3dnow,altivec only for single | |
233 | if [ "$ver" = "single" ]; then | |
f2b41f11 JB |
234 | %ifarch i686 |
235 | OPTS="--enable-sse" | |
8dd64783 | 236 | %endif |
f2b41f11 | 237 | %ifarch athlon |
376d0cb4 | 238 | OPTS="--enable-sse" # no "--enable-k7" - conflicts with shared, SEGV on athlons |
8dd64783 JB |
239 | %endif |
240 | %ifarch ppc | |
f2b41f11 | 241 | OPTS="--enable-altivec" |
5194fc97 | 242 | %endif |
5861ac73 | 243 | %ifnarch i686 k6 athlon ppc |
5194fc97 | 244 | : # keep sh happy about syntax |
8dd64783 | 245 | %endif |
8dd64783 JB |
246 | fi |
247 | %ifarch i686 | |
248 | # SSE2 only for double | |
249 | if [ "$ver" = "double" ]; then | |
250 | OPTS="--enable-sse2" | |
fb995851 | 251 | fi |
8dd64783 | 252 | %endif |
2e6b9bdb JB |
253 | install -d build-${ver} |
254 | cd build-${ver} | |
255 | ../%configure \ | |
8dd64783 JB |
256 | --enable-shared \ |
257 | --enable-threads \ | |
258 | --enable-$ver \ | |
259 | $OPTS \ | |
260 | --%{!?debug:dis}%{?debug:en}able-debug | |
261 | ||
262 | %{__make} | |
f2b41f11 | 263 | cd .. |
8dd64783 JB |
264 | done |
265 | ||
8dd64783 JB |
266 | %install |
267 | rm -rf $RPM_BUILD_ROOT | |
e6d90cf1 | 268 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/fftw |
8dd64783 | 269 | |
2e6b9bdb | 270 | %{__make} install -C build-single \ |
6fd39cfa | 271 | DESTDIR=$RPM_BUILD_ROOT |
8dd64783 | 272 | |
2e6b9bdb | 273 | %{__make} install -C build-double \ |
f2b41f11 | 274 | DESTDIR=$RPM_BUILD_ROOT |
8dd64783 | 275 | |
7de82846 | 276 | %if %{with fftwl} |
2e6b9bdb | 277 | %{__make} install -C build-long-double \ |
f2b41f11 | 278 | DESTDIR=$RPM_BUILD_ROOT |
7de82846 | 279 | %endif |
8dd64783 JB |
280 | |
281 | %clean | |
282 | rm -rf $RPM_BUILD_ROOT | |
283 | ||
284 | %post -p /sbin/ldconfig | |
285 | %postun -p /sbin/ldconfig | |
286 | ||
2fd5163a | 287 | %post single -p /sbin/ldconfig |
288 | %postun single -p /sbin/ldconfig | |
289 | ||
290 | %post long -p /sbin/ldconfig | |
291 | %postun long -p /sbin/ldconfig | |
292 | ||
a46795d7 | 293 | %post common-devel -p /sbin/postshell |
677edac6 | 294 | -/usr/sbin/fix-info-dir -c %{_infodir} |
8dd64783 | 295 | |
a46795d7 | 296 | %postun common-devel -p /sbin/postshell |
677edac6 | 297 | -/usr/sbin/fix-info-dir -c %{_infodir} |
8dd64783 JB |
298 | |
299 | %files | |
300 | %defattr(644,root,root,755) | |
f2b41f11 JB |
301 | %attr(755,root,root) %{_bindir}/fftw-wisdom |
302 | %attr(755,root,root) %{_libdir}/libfftw3.so.*.*.* | |
2e6b9bdb | 303 | %attr(755,root,root) %ghost %{_libdir}/libfftw3.so.3 |
f2b41f11 | 304 | %attr(755,root,root) %{_libdir}/libfftw3_threads.so.*.*.* |
2e6b9bdb | 305 | %attr(755,root,root) %ghost %{_libdir}/libfftw3_threads.so.3 |
f2b41f11 | 306 | %{_mandir}/man1/fftw-wisdom.1* |
8dd64783 JB |
307 | |
308 | %files devel | |
309 | %defattr(644,root,root,755) | |
f2b41f11 JB |
310 | %attr(755,root,root) %{_libdir}/libfftw3.so |
311 | %attr(755,root,root) %{_libdir}/libfftw3_threads.so | |
312 | %{_libdir}/libfftw3.la | |
313 | %{_libdir}/libfftw3_threads.la | |
314 | %{_pkgconfigdir}/fftw3.pc | |
8dd64783 JB |
315 | |
316 | %files static | |
317 | %defattr(644,root,root,755) | |
f2b41f11 JB |
318 | %{_libdir}/libfftw3.a |
319 | %{_libdir}/libfftw3_threads.a | |
320 | ||
321 | %files single | |
322 | %defattr(644,root,root,755) | |
323 | %attr(755,root,root) %{_bindir}/fftwf-wisdom | |
324 | %attr(755,root,root) %{_libdir}/libfftw3f.so.*.*.* | |
2e6b9bdb | 325 | %attr(755,root,root) %ghost %{_libdir}/libfftw3f.so.3 |
f2b41f11 | 326 | %attr(755,root,root) %{_libdir}/libfftw3f_threads.so.*.*.* |
2e6b9bdb | 327 | %attr(755,root,root) %ghost %{_libdir}/libfftw3f_threads.so.3 |
f2b41f11 JB |
328 | %{_mandir}/man1/fftwf-wisdom.1* |
329 | ||
330 | %files single-devel | |
331 | %defattr(644,root,root,755) | |
332 | %attr(755,root,root) %{_libdir}/libfftw3f.so | |
333 | %attr(755,root,root) %{_libdir}/libfftw3f_threads.so | |
334 | %{_libdir}/libfftw3f.la | |
335 | %{_libdir}/libfftw3f_threads.la | |
336 | %{_pkgconfigdir}/fftw3f.pc | |
337 | ||
338 | %files single-static | |
339 | %defattr(644,root,root,755) | |
340 | %{_libdir}/libfftw3f.a | |
341 | %{_libdir}/libfftw3f_threads.a | |
342 | ||
7de82846 | 343 | %if %{with fftwl} |
f2b41f11 JB |
344 | %files long |
345 | %defattr(644,root,root,755) | |
346 | %attr(755,root,root) %{_bindir}/fftwl-wisdom | |
347 | %attr(755,root,root) %{_libdir}/libfftw3l.so.*.*.* | |
2e6b9bdb | 348 | %attr(755,root,root) %ghost %{_libdir}/libfftw3l.so.3 |
f2b41f11 | 349 | %attr(755,root,root) %{_libdir}/libfftw3l_threads.so.*.*.* |
2e6b9bdb | 350 | %attr(755,root,root) %ghost %{_libdir}/libfftw3l_threads.so.3 |
f2b41f11 JB |
351 | %{_mandir}/man1/fftwl-wisdom.1* |
352 | ||
353 | %files long-devel | |
354 | %defattr(644,root,root,755) | |
355 | %attr(755,root,root) %{_libdir}/libfftw3l.so | |
356 | %attr(755,root,root) %{_libdir}/libfftw3l_threads.so | |
357 | %{_libdir}/libfftw3l.la | |
358 | %{_libdir}/libfftw3l_threads.la | |
359 | %{_pkgconfigdir}/fftw3l.pc | |
360 | ||
361 | %files long-static | |
362 | %defattr(644,root,root,755) | |
363 | %{_libdir}/libfftw3l.a | |
364 | %{_libdir}/libfftw3l_threads.a | |
7de82846 | 365 | %endif |
f2b41f11 JB |
366 | |
367 | %files common | |
368 | %defattr(644,root,root,755) | |
369 | %doc AUTHORS COPYRIGHT ChangeLog NEWS README TODO | |
e6d90cf1 | 370 | %dir %{_sysconfdir}/fftw |
f2b41f11 JB |
371 | %attr(755,root,root) %{_bindir}/fftw-wisdom-to-conf |
372 | %{_mandir}/man1/fftw-wisdom-to-conf.1* | |
373 | ||
374 | %files common-devel | |
375 | %defattr(644,root,root,755) | |
376 | %doc doc/html doc/FAQ/fftw-faq.html | |
2e6b9bdb JB |
377 | %{_includedir}/fftw3.f |
378 | %{_includedir}/fftw3.h | |
f2b41f11 | 379 | %{_infodir}/fftw3.info* |