diff options
author | Nate Ohlson <nohlson@purdue.edu> | 2024-06-26 08:45:55 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-26 08:45:55 (GMT) |
commit | d8f82432a36178a2376cc2d0984b02bb03f6d55f (patch) | |
tree | ec086e2809ee0fa80330271dbe8b6e00ec9f5de6 /configure.ac | |
parent | 0654336dd5138aec04e3017e15ccbb90a44e053d (diff) | |
download | cpython-d8f82432a36178a2376cc2d0984b02bb03f6d55f.zip cpython-d8f82432a36178a2376cc2d0984b02bb03f6d55f.tar.gz cpython-d8f82432a36178a2376cc2d0984b02bb03f6d55f.tar.bz2 |
gh-121026: Include -Werror with new compiler flag checks to ensure compatibility (gh-121030)
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac index e5c6d6f..33dee0a 100644 --- a/configure.ac +++ b/configure.ac @@ -2453,13 +2453,9 @@ AS_VAR_IF([with_strict_overflow], [yes], # Enable flags that warn and protect for potential security vulnerabilities. # These flags should be enabled by default for all builds. -AX_CHECK_COMPILE_FLAG([-Wimplicit-fallthrough], [BASECFLAGS="$BASECFLAGS -Wimplicit-fallthrough"], [AC_MSG_WARN([-Wimplicit-fallthrough not supported])]) -AX_CHECK_COMPILE_FLAG([-fstack-protector-strong], [BASECFLAGS="$BASECFLAGS -fstack-protector-strong"], [AC_MSG_WARN([-fstack-protector-strong not supported])]) -case $CC in - *gcc*) - # Add GCC-specific compiler flags - AX_CHECK_COMPILE_FLAG([-Wtrampolines], [BASECFLAGS="$BASECFLAGS -Wtrampolines"], [AC_MSG_WARN([-Wtrampolines not supported])]) -esac +AX_CHECK_COMPILE_FLAG([-Wimplicit-fallthrough], [BASECFLAGS="$BASECFLAGS -Wimplicit-fallthrough"], [AC_MSG_WARN([-Wimplicit-fallthrough not supported])], [-Werror]) +AX_CHECK_COMPILE_FLAG([-fstack-protector-strong], [BASECFLAGS="$BASECFLAGS -fstack-protector-strong"], [AC_MSG_WARN([-fstack-protector-strong not supported])], [-Werror]) +AX_CHECK_COMPILE_FLAG([-Wtrampolines], [BASECFLAGS="$BASECFLAGS -Wtrampolines"], [AC_MSG_WARN([-Wtrampolines not supported])], [-Werror]) case $GCC in yes) |