[fftw] Fix FTBFS.

Jussi Lehtola jussilehtola at fedoraproject.org
Fri Apr 27 09:00:34 UTC 2012


commit f06091dbe544219bc49bea295b04dd51b6ce8fa4
Author: Jussi Lehtola <jussilehtola at fedoraproject.org>
Date:   Fri Apr 27 12:00:31 2012 +0300

    Fix FTBFS.

 fftw-3.3.1-alignment.patch |   12 ++++++++++++
 fftw.spec                  |   11 ++++++++++-
 2 files changed, 22 insertions(+), 1 deletions(-)
---
diff --git a/fftw-3.3.1-alignment.patch b/fftw-3.3.1-alignment.patch
new file mode 100644
index 0000000..8ff6f7e
--- /dev/null
+++ b/fftw-3.3.1-alignment.patch
@@ -0,0 +1,12 @@
+diff -up fftw-3.3.1/libbench2/aligned-main.c.orig fftw-3.3.1/libbench2/aligned-main.c
+--- fftw-3.3.1/libbench2/aligned-main.c.orig	2012-02-20 18:04:55.000000000 +0200
++++ fftw-3.3.1/libbench2/aligned-main.c	2012-04-27 10:57:26.832958730 +0300
+@@ -48,7 +48,7 @@ int aligned_main(int argc, char *argv[])
+ 	  /*
+ 	   * Now align the stack pointer
+ 	   */
+-	  __asm__ __volatile__ ("andl $-16, %esp");
++	/*  __asm__ __volatile__ ("andl $-16, %esp");*/
+ 
+ #  ifdef FFTW_DEBUG_ALIGNMENT
+ 	  /* pessimally align the stack, in order to check whether the
diff --git a/fftw.spec b/fftw.spec
index a011a60..8da9e5d 100644
--- a/fftw.spec
+++ b/fftw.spec
@@ -1,11 +1,13 @@
 Name:           fftw
 Version:        3.3.1
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        A Fast Fourier Transform library
 Group:          System Environment/Libraries
 License:        GPLv2+
 URL:            http://www.fftw.org
 Source0:        http://www.fftw.org/fftw-%{version}.tar.gz
+# Patch around gcc 4.7, obtained from upstream
+Patch0:		fftw-3.3.1-alignment.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 # OpenMP support not available on RHEL 4
@@ -138,6 +140,10 @@ library.
 
 %prep
 %setup -q
+%if 0%{?fedora} == 17 || 0%{?fedora} == 18
+%patch0 -p1 -b .alignment
+%endif
+
 
 %build
 %if 0%{?rhel} == 4
@@ -292,6 +298,9 @@ fi
 %{_libdir}/libfftw3*.a
 
 %changelog
+* Fri Apr 27 2012 Jussi Lehtola <jussilehtola at fedoraproject.org> - 3.3.1-3
+- Fix FTBFS with gcc 4.7.
+
 * Thu Apr 26 2012 Jussi Lehtola <jussilehtola at fedoraproject.org> - 3.3.1-2
 - Reorganized libraries (BZ #812981).
 


More information about the scm-commits mailing list