From b5a434f7f0ee4d64857f8592eced5b9007d83620 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Mon, 28 Jun 2021 17:01:29 +0200 Subject: configure: inhibit the implicit-fallthrough warning on gcc-12 ... since it no longer acknowledges the comment markup we use for that purpose. Reported-by: Younes El-karama Fixes #7295 Closes #7307 --- m4/curl-compilers.m4 | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'm4') diff --git a/m4/curl-compilers.m4 b/m4/curl-compilers.m4 index 485e6017e..6d17a9fbd 100644 --- a/m4/curl-compilers.m4 +++ b/m4/curl-compilers.m4 @@ -1033,7 +1033,10 @@ AC_DEFUN([CURL_SET_COMPILER_WARNING_OPTS], [ CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [alloc-zero]) tmp_CFLAGS="$tmp_CFLAGS -Wformat-overflow=2" tmp_CFLAGS="$tmp_CFLAGS -Wformat-truncation=2" - tmp_CFLAGS="$tmp_CFLAGS -Wimplicit-fallthrough=4" + if test "$compiler_num" -lt "1200"; then + dnl gcc 12 doesn't acknowledge our comment markups + tmp_CFLAGS="$tmp_CFLAGS -Wimplicit-fallthrough=4" + fi fi # fi -- cgit v1.2.1