]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Restrict -Wa,-nH use to Solaris (PR libstdc++/55594)
authorRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Tue, 8 Jan 2013 09:47:55 +0000 (09:47 +0000)
committerRainer Orth <ro@gcc.gnu.org>
Tue, 8 Jan 2013 09:47:55 +0000 (09:47 +0000)
PR libstdc++/55594
* acinclude.m4 (GLIBCXX_CHECK_ASSEMBLER_HWCAP): Restrict test to
Solaris targets.
* configure: Regenerate.

From-SVN: r195009

libstdc++-v3/ChangeLog
libstdc++-v3/acinclude.m4
libstdc++-v3/configure

index e043d6bb89e12a4e262682c34ad800f399a5c28f..9d0a6d7574ab180732f17c55b30eaa65ed0cee7c 100644 (file)
@@ -1,3 +1,10 @@
+2013-01-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
+
+       PR libstdc++/55594
+       * acinclude.m4 (GLIBCXX_CHECK_ASSEMBLER_HWCAP): Restrict test to
+       Solaris targets.
+       * configure: Regenerate.
+
 2013-01-07  Jonathan Wakely  <jwakely.gcc@gmail.com>
 
        PR libstdc++/55847
index 2d4d7f022f9022cc15a17f45ec8711af0fc1cfda..528ce8320e69abcd4e5f60b3d97b949589645f18 100644 (file)
@@ -178,17 +178,23 @@ dnl
 AC_DEFUN([GLIBCXX_CHECK_ASSEMBLER_HWCAP], [
   test -z "$HWCAP_FLAGS" && HWCAP_FLAGS=''
 
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS -Wa,-nH"
+  # Restrict the test to Solaris, other assemblers (e.g. AIX as) have -nH
+  # with a different meaning.
+  case ${target_os} in
+    solaris2*)
+      ac_save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wa,-nH"
 
-  AC_MSG_CHECKING([for as that supports -Wa,-nH])
-  AC_TRY_COMPILE([], [return 0;], [ac_hwcap_flags=yes],[ac_hwcap_flags=no])
-  if test "$ac_hwcap_flags" = "yes"; then
-    HWCAP_FLAGS="-Wa,-nH $HWCAP_FLAGS"
-  fi
-  AC_MSG_RESULT($ac_hwcap_flags)
+      AC_MSG_CHECKING([for as that supports -Wa,-nH])
+      AC_TRY_COMPILE([], [return 0;], [ac_hwcap_flags=yes],[ac_hwcap_flags=no])
+      if test "$ac_hwcap_flags" = "yes"; then
+       HWCAP_FLAGS="-Wa,-nH $HWCAP_FLAGS"
+      fi
+      AC_MSG_RESULT($ac_hwcap_flags)
 
-  CFLAGS="$ac_save_CFLAGS"
+      CFLAGS="$ac_save_CFLAGS"
+      ;;
+  esac
 
   AC_SUBST(HWCAP_FLAGS)
 ])
index 9e8360200b46d85ad5bcc916f6184005fbd9e7ee..a4cf5c9f8cf5703e7479c99bda0495347fabf78a 100755 (executable)
@@ -70790,12 +70790,16 @@ esac
 
   test -z "$HWCAP_FLAGS" && HWCAP_FLAGS=''
 
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS -Wa,-nH"
+  # Restrict the test to Solaris, other assemblers (e.g. AIX as) have -nH
+  # with a different meaning.
+  case ${target_os} in
+    solaris2*)
+      ac_save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wa,-nH"
 
-  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for as that supports -Wa,-nH" >&5
+      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for as that supports -Wa,-nH" >&5
 $as_echo_n "checking for as that supports -Wa,-nH... " >&6; }
-  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
 int
@@ -70812,13 +70816,15 @@ else
   ac_hwcap_flags=no
 fi
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-  if test "$ac_hwcap_flags" = "yes"; then
-    HWCAP_FLAGS="-Wa,-nH $HWCAP_FLAGS"
-  fi
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_hwcap_flags" >&5
+      if test "$ac_hwcap_flags" = "yes"; then
+       HWCAP_FLAGS="-Wa,-nH $HWCAP_FLAGS"
+      fi
+      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_hwcap_flags" >&5
 $as_echo "$ac_hwcap_flags" >&6; }
 
-  CFLAGS="$ac_save_CFLAGS"
+      CFLAGS="$ac_save_CFLAGS"
+      ;;
+  esac