aboutsummaryrefslogtreecommitdiff
path: root/libgo/configure
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@gcc.gnu.org>2012-02-08 19:38:17 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2012-02-08 19:38:17 +0000
commit9d465faf92900b572286d6e9701632c2b289b451 (patch)
treea1a0850efce956decdd30ccf8cc67d64ab875d26 /libgo/configure
parent82b37806c51b3fa8cffa4876c0609e6a6801e02d (diff)
downloadgcc-9d465faf92900b572286d6e9701632c2b289b451.zip
gcc-9d465faf92900b572286d6e9701632c2b289b451.tar.gz
gcc-9d465faf92900b572286d6e9701632c2b289b451.tar.bz2
math: Compile with -mfancy-math-387 -funsafe-optimizations on x86.
From-SVN: r184015
Diffstat (limited to 'libgo/configure')
-rwxr-xr-xlibgo/configure32
1 files changed, 30 insertions, 2 deletions
diff --git a/libgo/configure b/libgo/configure
index 9b65c25..5821d32 100755
--- a/libgo/configure
+++ b/libgo/configure
@@ -604,6 +604,7 @@ LTLIBOBJS
LIBOBJS
STRUCT_EPOLL_EVENT_FD_OFFSET
SIZEOF_STRUCT_EPOLL_EVENT
+MATH_FLAG
STRINGOPS_FLAG
HAVE_WAIT4_FALSE
HAVE_WAIT4_TRUE
@@ -11101,7 +11102,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11104 "configure"
+#line 11105 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -11207,7 +11208,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11210 "configure"
+#line 11211 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -14707,6 +14708,33 @@ if test "$libgo_cv_c_stringops" = yes; then
fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -mfancy-math-387" >&5
+$as_echo_n "checking whether compiler supports -mfancy-math-387... " >&6; }
+if test "${libgo_cv_c_fancymath+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ CFLAGS_hold=$CFLAGS
+CFLAGS="$CFLAGS -mfancy-math-387"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int i;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+ libgo_cv_c_fancymath=yes
+else
+ libgo_cv_c_fancymath=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+CFLAGS=$CFLAGS_hold
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libgo_cv_c_fancymath" >&5
+$as_echo "$libgo_cv_c_fancymath" >&6; }
+MATH_FLAG=
+if test "$libgo_cv_c_fancymath" = yes; then
+ MATH_FLAG="-mfancy-math-387 -funsafe-math-optimizations"
+fi
+
+
CFLAGS_hold=$CFLAGS
CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
ac_fn_c_check_type "$LINENO" "off64_t" "ac_cv_type_off64_t" "$ac_includes_default"