%bcond_without gfortran Summary: Fast Fourier Transform library Name: fftw2 Version: 2.1.5 Release: 14%{?dist} License: GPL Group: System Environment/Libraries Source: http://www.fftw.org/fftw-%{version}.tar.gz URL: http://www.fftw.org/ BuildRoot: %{_tmppath}/%{name}-root %{?with_gfortran:BuildRequires: gcc-gfortran} %{!?with_gfortran:BuildRequires: gcc-g77} Requires: %{name}-double, %{name}-single Obsoletes: fftw <= %{eversion} %description FFTW is a C subroutine library for computing the Discrete Fourier Transform (DFT) in one or more dimensions, of both real and complex data, and of arbitrary input size. We believe that FFTW, which is free software, should become the FFT library of choice for most applications. Our benchmarks, performed on on a variety of platforms, show that FFTW's performance is typically superior to that of other publicly available FFT software. %package double Summary: Fast Fourier Transform library for double precision Group: System Environment/Libraries Requires: /sbin/ldconfig Obsoletes: fftw <= %{eversion} %description double FFTW is a C subroutine library for computing the Discrete Fourier Transform (DFT) in one or more dimensions, of both real and complex data, and of arbitrary input size. We believe that FFTW, which is free software, should become the FFT library of choice for most applications. Our benchmarks, performed on on a variety of platforms, show that FFTW's performance is typically superior to that of other publicly available FFT software. This package contains fftw built for double precision %package single Summary: Fast Fourier Transform library for single precision Group: System Environment/Libraries Requires: /sbin/ldconfig #Provides: libfftw.so.2, libfftw_threads.so.2, librfftw.so.2, librfftw_threads.so.2 Obsoletes: fftw <= %{eversion}, fftw-single <= %{eversion} %description single FFTW is a C subroutine library for computing the Discrete Fourier Transform (DFT) in one or more dimensions, of both real and complex data, and of arbitrary input size. We believe that FFTW, which is free software, should become the FFT library of choice for most applications. Our benchmarks, performed on on a variety of platforms, show that FFTW's performance is typically superior to that of other publicly available FFT software. This package contains fftw built for single precision %package devel Summary: Headers, libraries and docs for the FFTW library Group: Development/Libraries Requires: %{name} = %{eversion} Requires: %{name}-double-devel, %{name}-single-devel Obsoletes: fftw-devel <= %{eversion} %description devel This package contains header files and development libraries needed to develop programs using the FFTW fast Fourier transform library. %package double-devel Summary: Headers, libraries and docs for the double precision FFTW library Group: Development/Libraries Requires: %{name}-double = %{evr} Obsoletes: fftw-devel < %{evr} %description double-devel This package contains header files and development libraries needed to develop programs using the double precision FFTW fast Fourier transform library. %package single-devel Summary: Headers, libraries and docs for the single precision FFTW library Group: Development/Libraries Requires: %{name}-single = %{evr} Obsoletes: fftw-devel < %{evr} %description single-devel This package contains header files and development libraries needed to develop programs using the single precision FFTW fast Fourier transform library. %prep %setup -q -n fftw-%{version} %build mkdir double # Configuring out of the tree does not work mkdir temp mv * temp || : cp -a temp single mv temp/* . rmdir temp %configure \ --enable-shared \ --enable-threads \ %ifarch %ix86 --enable-i386-hacks \ %endif --enable-type-prefix make cd single %configure --enable-shared \ --enable-threads \ %ifarch %ix86 --enable-i386-hacks \ %endif --enable-type-prefix \ --enable-float \ --enable-type-prefix make cd .. %check make check cd single make check cd .. %install rm -rf %{buildroot} make install DESTDIR="%{buildroot}" cd single make install DESTDIR="%{buildroot}" cd .. default=d ls %{buildroot}%{_includedir}/${default}*.h \ %{buildroot}%{_libdir}/lib${default}*.{so,a,la} \ | sed -e"s,^%{buildroot}%{_includedir}/${default},%{_includedir}/," \ | sed -e"s,^%{buildroot}%{_libdir}/lib${default},%{_libdir}/lib," \ > fftw2-devel.files sed -e"s,%{_includedir}/\(.*\),ln -s ${default}\1 %{buildroot}%{_includedir}/\1," \ -e"s,%{_libdir}/lib\(.*\),ln -s lib${default}\1 %{buildroot}%{_libdir}/lib\1," \ < fftw2-devel.files | sh -x rm -f %{buildroot}%{_infodir}/dir %clean rm -rf %{buildroot} %post devel infofile=%{_infodir}/fftw.info if [ -f $infofile.gz ]; then infofile=$infofile.gz; fi /sbin/install-info $infofile %{_infodir}/dir %preun devel if [ $1 = 0 ]; then infofile=%{_infodir}/fftw.info if [ -f $infofile.gz ]; then infofile=$infofile.gz; fi /sbin/install-info --del $infofile %{_infodir}/dir fi %post single -p /sbin/ldconfig %postun single -p /sbin/ldconfig %post double -p /sbin/ldconfig %postun double -p /sbin/ldconfig %files %defattr(-,root,root,-) %doc AUTHORS COPYING COPYRIGHT ChangeLog NEWS README* TODO %files double %defattr(-,root,root,-) %{_libdir}/libd*.so.* %files single %defattr(-,root,root,-) %{_libdir}/libs*.so.* %files devel %defattr(-,root,root,-) %doc FAQ/fftw-faq.html/ doc/ %{_infodir}/fftw.info* %files double-devel -f fftw2-devel.files %defattr(-,root,root,-) %{_includedir}/d* %{_libdir}/libd*.a %{_libdir}/libd*.la %{_libdir}/libd*.so %files single-devel %defattr(-,root,root,-) %{_includedir}/s* %{_libdir}/libs*.a %{_libdir}/libs*.la %{_libdir}/libs*.so %changelog * Sun Jan 14 2007 Axel Thimm - 2.1.5-13 - Fix bug #1088. * Mon Oct 21 2002 Matthias Saou - Initial RPM release.