[libstdc++, 3.3?] Fix --enable-cxx-flags
Phil Edwards
phil@jaj.com
Mon Dec 30 07:12:00 GMT 2002
When this file was last edited, Benjamin accidentally put the ending ')'
of AC_ARG_ENABLE too early. The resulting logic was, "if this option was
given, set it to off." :-)
The relevant part of the patch is given below. I also removed trailing
whitespace throughout the file, which makes for a large and boring diff.
Tested on i686/linux gnu, no problems, and applied to trunk. I think
the bug is also on the 3.3 branch but haven't checked yet. If it is,
I'll test and commit the same fix there.
2002-12-30 Phil Edwards <pme@gcc.gnu.org>
* acinclude.m4: Remove trailing whitespace.
(GLIBCPP_ENABLE_CXX_FLAGS): Fix.
* aclocal.m4, configure: Regenerate.
Index: acinclude.m4
===================================================================
RCS file: /home/pme/Repositories/GCC/gcc/libstdc++-v3/acinclude.m4,v
retrieving revision 1.224
diff -u -3 -r1.224 acinclude.m4
--- acinclude.m4 16 Dec 2002 19:01:43 -0000 1.224
+++ acinclude.m4 30 Dec 2002 03:25:20 -0000
@@ -1145,21 +1145,21 @@
dnl the same as --disable or --enable=no.
AC_DEFUN(GLIBCPP_ENABLE_CXX_FLAGS, [dnl
define([GLIBCPP_ENABLE_CXX_FLAGS_DEFAULT], ifelse($1,,, $1))dnl
+AC_MSG_CHECKING([for extra compiler flags for building])
AC_ARG_ENABLE(cxx_flags,
changequote(<<, >>)dnl
<< --enable-cxx-flags=FLAGS pass compiler FLAGS when building library;
- [default=>>GLIBCPP_ENABLE_CXX_FLAGS_DEFAULT],
+ [default=>>GLIBCPP_ENABLE_CXX_FLAGS_DEFAULT],
changequote([, ])dnl
-enable_cxx_flags='GLIBCPP_ENABLE_CXX_FLAGS_DEFAULT')
-
-case "x$enable_cxx_flags" in
- xyes)
- AC_MSG_ERROR([--enable-cxx-flags needs compiler flags as arguments]) ;;
- xno | xnone | x)
- enable_cxx_flags='' ;;
- *)
- enable_cxx_flags="$enableval" ;;
-esac
+[case "x$enable_cxx_flags" in
+ xyes)
+ AC_MSG_ERROR([--enable-cxx-flags needs compiler flags as arguments]) ;;
+ xno | xnone | x)
+ enable_cxx_flags='' ;;
+ *)
+ enable_cxx_flags="$enableval" ;;
+esac],
+enable_cxx_flags=GLIBCPP_ENABLE_CXX_FLAGS_DEFAULT)
dnl Run through flags (either default or command-line) and set anything
dnl extra (e.g., #defines) that must accompany particular g++ options.
@@ -1174,6 +1174,7 @@
done
fi
EXTRA_CXX_FLAGS="$enable_cxx_flags"
+AC_MSG_RESULT($EXTRA_CXX_FLAGS)
AC_SUBST(EXTRA_CXX_FLAGS)
])
More information about the Libstdc++
mailing list