From 847f00f63cd3c744dd4a3e9d9b7a41ec71a3b051 Mon Sep 17 00:00:00 2001 From: hjl Date: Mon, 25 Apr 2016 12:41:43 +0000 Subject: [PATCH] Revert the last change in libatomic Need to properly check if -march=i486 is really needed for -m32 build of libatomic on Linux/x86 and Linux/x86-64. PR target/70454 * configure.tgt (XCFLAGS): Revert the last change. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@235411 138bc75d-0d04-0410-961f-82ee72b054a4 --- libatomic/ChangeLog | 5 +++++ libatomic/configure.tgt | 10 ++++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/libatomic/ChangeLog b/libatomic/ChangeLog index 70a7f7ceca1f..7fc60c220852 100644 --- a/libatomic/ChangeLog +++ b/libatomic/ChangeLog @@ -1,3 +1,8 @@ +2016-04-25 H.J. Lu + + PR target/70454 + * configure.tgt (XCFLAGS): Revert the last change. + 2016-04-20 H.J. Lu PR target/70454 diff --git a/libatomic/configure.tgt b/libatomic/configure.tgt index 49233a4f45ae..c5470d7ef8c3 100644 --- a/libatomic/configure.tgt +++ b/libatomic/configure.tgt @@ -81,8 +81,14 @@ case "${target_cpu}" in try_ifunc=yes ;; x86_64) - # x86_64 compiler passes -march=x86_64 by default when building - # 32bit target libraries. + case " ${CC} ${CFLAGS} " in + *" -m32 "*) + XCFLAGS="${XCFLAGS} -march=i486 -mtune=generic" + XCFLAGS="${XCFLAGS} -fomit-frame-pointer" + ;; + *) + ;; + esac ARCH=x86 # ??? Detect when -mcx16 is already enabled. try_ifunc=yes -- 2.47.3