GCC needs C++14, which makes -Wno-long-long redundant.
Move from strict_warn to c_strict_warn since at least C89
is needed.
Bootstrapped on x86_64-pc-linux-gnu.
PR bootstrap/112422
libcpp/ChangeLog:
* configure.ac (-Wno-long-long): Move from strict_warn
to c_strict_warn.
* configure: Regenerate.
---
gcc/configure | 22 +++++++++++-----------
gcc/configure.ac | 4 ++--
2 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/gcc/configure b/gcc/configure
index e45605b7340..0b45c7d7f03 100755
--- a/gcc/configure
+++ b/gcc/configure
@@ -7275,7 +7275,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
c_strict_warn=
save_CFLAGS="$CFLAGS"
-for real_option in -Wold-style-definition -Wc++-compat; do
+for real_option in -Wno-long-long -Wold-style-definition -Wc++-compat; do
# Do the check with the no- prefix removed since gcc silently
# accepts any -Wno-* option on purpose
case $real_option in
@@ -7333,13 +7333,13 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
# Do the check with the no- prefix removed from the warning options
# since gcc silently accepts any -Wno-* option on purpose
if test "$GXX" = yes; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports
-pedantic -Wlong-long -Wvariadic-macros -Woverlength-strings" >&5
-$as_echo_n "checking whether $CXX supports -pedantic -Wlong-long
-Wvariadic-macros -Woverlength-strings... " >&6; }
-if
${acx_cv_prog_cc_pedantic__Wlong_long__Wvariadic_macros__Woverlength_strings+:}
false; then :
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports
-pedantic -Wvariadic-macros -Woverlength-strings" >&5
+$as_echo_n "checking whether $CXX supports -pedantic -Wvariadic-macros
-Woverlength-strings... " >&6; }
+if ${acx_cv_prog_cc_pedantic__Wvariadic_macros__Woverlength_strings+:} false;
then :
$as_echo_n "(cached) " >&6
else
save_CXXFLAGS="$CXXFLAGS"
-CXXFLAGS="-pedantic -Wlong-long -Wvariadic-macros -Woverlength-strings"
+CXXFLAGS="-pedantic -Wvariadic-macros -Woverlength-strings"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -7352,17 +7352,17 @@ main ()
}
_ACEOF
if ac_fn_cxx_try_compile "$LINENO"; then :
-
acx_cv_prog_cc_pedantic__Wlong_long__Wvariadic_macros__Woverlength_strings=yes
+ acx_cv_prog_cc_pedantic__Wvariadic_macros__Woverlength_strings=yes
else
- acx_cv_prog_cc_pedantic__Wlong_long__Wvariadic_macros__Woverlength_strings=no
+ acx_cv_prog_cc_pedantic__Wvariadic_macros__Woverlength_strings=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CXXFLAGS="$save_CXXFLAGS"
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result:
$acx_cv_prog_cc_pedantic__Wlong_long__Wvariadic_macros__Woverlength_strings" >&5
-$as_echo
"$acx_cv_prog_cc_pedantic__Wlong_long__Wvariadic_macros__Woverlength_strings"
>&6; }
-if test
$acx_cv_prog_cc_pedantic__Wlong_long__Wvariadic_macros__Woverlength_strings =
yes; then :
- strict_warn="$strict_warn${strict_warn:+ }-pedantic -Wno-long-long
-Wno-variadic-macros -Wno-overlength-strings"
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result:
$acx_cv_prog_cc_pedantic__Wvariadic_macros__Woverlength_strings" >&5
+$as_echo "$acx_cv_prog_cc_pedantic__Wvariadic_macros__Woverlength_strings"
>&6; }
+if test $acx_cv_prog_cc_pedantic__Wvariadic_macros__Woverlength_strings = yes;
then :
+ strict_warn="$strict_warn${strict_warn:+ }-pedantic -Wno-variadic-macros
-Wno-overlength-strings"
fi
fi
diff --git a/gcc/configure.ac b/gcc/configure.ac
index 49008385924..70dd5b11807 100644
--- a/gcc/configure.ac
+++ b/gcc/configure.ac
@@ -580,9 +580,9 @@ ACX_PROG_CXX_WARNING_OPTS(
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])
+ m4_quote(m4_do([-Wno-long-long -Wold-style-definition -Wc++-compat])),
[c_strict_warn])
ACX_PROG_CXX_WARNING_ALMOST_PEDANTIC(
- m4_quote(m4_do([-Wno-long-long -Wno-variadic-macros ],
+ m4_quote(m4_do([-Wno-variadic-macros ],
[-Wno-overlength-strings])), [strict_warn])
ACX_PROG_CXX_WARNINGS_ARE_ERRORS([manual], [strict_warn])
--
2.56.0