From ff8ebda16a00b9f745d213f72f57c27043e07f85 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Tue, 13 Jan 2015 15:57:27 +0000 Subject: [PATCH] Set TARGET to X86_64 if __x86_64__ is defined PR bootstrap/64575 * configure.host (TARGET): Set to X86_64 if __x86_64__ is defined. From-SVN: r219539 --- libffi/ChangeLog | 5 +++++ libffi/configure.host | 8 +++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/libffi/ChangeLog b/libffi/ChangeLog index cbdb173ca60..15661204a09 100644 --- a/libffi/ChangeLog +++ b/libffi/ChangeLog @@ -1,3 +1,8 @@ +2015-01-13 H.J. Lu + + PR bootstrap/64575 + * configure.host (TARGET): Set to X86_64 if __x86_64__ is defined. + 2015-01-12 Richard Henderson PR libffi/64572 diff --git a/libffi/configure.host b/libffi/configure.host index 90de638b30c..e310191e018 100644 --- a/libffi/configure.host +++ b/libffi/configure.host @@ -100,7 +100,13 @@ case "${host}" in TARGET=X86_64 ;; *) - TARGET=X86 + echo 'int foo (void) { return __x86_64__; }' > conftest.c + if $CC $CFLAGS -Werror -S conftest.c -o conftest.s > /dev/null 2>&1; then + TARGET=X86_64; + else + TARGET=X86; + fi + rm -f conftest.* ;; esac else -- 2.30.2