From: Jason Merrill Date: Mon, 5 Dec 2022 15:00:31 +0000 (-0500) Subject: build: add -Wconditionally-supported to strict_warn [PR64867] X-Git-Tag: basepoints/gcc-14~2412 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=263c22a95bc9a0d80c4873c0291b0f938cea7310;p=thirdparty%2Fgcc.git build: add -Wconditionally-supported to strict_warn [PR64867] The PR (which isn't resolved by this commit) pointed out to me that GCC should build with -Wconditionally-supported to support bootstrapping with a C++11 compiler that makes different choices. PR c++/64867 gcc/ChangeLog: * configure.ac (strict_warn): Add -Wconditionally-supported. * configure: Regenerate. --- diff --git a/gcc/configure b/gcc/configure index 61b3cedbe693..921aad607127 100755 --- a/gcc/configure +++ b/gcc/configure @@ -7215,7 +7215,7 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu strict_warn= save_CXXFLAGS="$CXXFLAGS" -for real_option in -Wmissing-format-attribute -Woverloaded-virtual; do +for real_option in -Wmissing-format-attribute -Wconditionally-supported -Woverloaded-virtual; do # Do the check with the no- prefix removed since gcc silently # accepts any -Wno-* option on purpose case $real_option in diff --git a/gcc/configure.ac b/gcc/configure.ac index 5efbf11793cf..b91f54ce05bc 100644 --- a/gcc/configure.ac +++ b/gcc/configure.ac @@ -580,7 +580,7 @@ ACX_PROG_CC_WARNING_OPTS( m4_quote(m4_do([-Wstrict-prototypes -Wmissing-prototypes ], [])), [c_loose_warn]) ACX_PROG_CXX_WARNING_OPTS( - m4_quote(m4_do([-Wmissing-format-attribute ], + m4_quote(m4_do([-Wmissing-format-attribute ], [-Wconditionally-supported ], [-Woverloaded-virtual])), [strict_warn]) ACX_PROG_CC_WARNING_OPTS( m4_quote(m4_do([-Wold-style-definition -Wc++-compat])), [c_strict_warn])