x86 pcrel test part 2
authorAnthony Green <green@moxielogic.com>
Tue, 8 Feb 2011 15:11:00 +0000 (10:11 -0500)
committerAnthony Green <green@moxielogic.com>
Tue, 8 Feb 2011 15:11:00 +0000 (10:11 -0500)
.pc/x86_pcrel_test/.timestamp [new file with mode: 0644]
patches/x86_pcrel_test [new file with mode: 0644]

diff --git a/.pc/x86_pcrel_test/.timestamp b/.pc/x86_pcrel_test/.timestamp
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/patches/x86_pcrel_test b/patches/x86_pcrel_test
new file mode 100644 (file)
index 0000000..a8fd8c4
--- /dev/null
@@ -0,0 +1,49 @@
+Index: libffi/ChangeLog
+===================================================================
+--- libffi.orig/ChangeLog
++++ libffi/ChangeLog
+@@ -1,3 +1,8 @@
++2011-02-08  Rafael Avila de Espindola  <respindola@mozilla.com>
++
++      * configure.ac: Fix x86 test for pc related relocs.
++      * confifure: Rebuilt.
++
+ 2011-01-26  Dave Korn  <dave.korn.cygwin@gmail.com>
+       PR target/40125
+Index: libffi/configure
+===================================================================
+--- libffi.orig/configure
++++ libffi/configure
+@@ -14517,10 +14517,10 @@ if test "${libffi_cv_as_x86_pcrel+set}" 
+   $as_echo_n "(cached) " >&6
+ else
+-      libffi_cv_as_x86_pcrel=yes
++      libffi_cv_as_x86_pcrel=no
+       echo '.text; foo: nop; .data; .long foo-.; .text' > conftest.s
+-      if $CC $CFLAGS -c conftest.s 2>&1 | $EGREP -i 'illegal|warning' > /dev/null; then
+-          libffi_cv_as_x86_pcrel=no
++      if $CC $CFLAGS -c conftest.s > /dev/null; then
++         libffi_cv_as_x86_pcrel=yes
+       fi
+ fi
+Index: libffi/configure.ac
+===================================================================
+--- libffi.orig/configure.ac
++++ libffi/configure.ac
+@@ -283,10 +283,10 @@ fi
+ if test x$TARGET = xX86 || test x$TARGET = xX86_WIN32 || test x$TARGET = xX86_64; then
+     AC_CACHE_CHECK([assembler supports pc related relocs],
+       libffi_cv_as_x86_pcrel, [
+-      libffi_cv_as_x86_pcrel=yes
++      libffi_cv_as_x86_pcrel=no
+       echo '.text; foo: nop; .data; .long foo-.; .text' > conftest.s
+-      if $CC $CFLAGS -c conftest.s 2>&1 | $EGREP -i 'illegal|warning' > /dev/null; then
+-          libffi_cv_as_x86_pcrel=no
++      if $CC $CFLAGS -c conftest.s > /dev/null; then
++         libffi_cv_as_x86_pcrel=yes
+       fi
+       ])
+     if test "x$libffi_cv_as_x86_pcrel" = xyes; then