[openssh-commits] [openssh] 01/01: Build with -Werror on most recent gcc and clang.
git+noreply at mindrot.org
git+noreply at mindrot.org
Thu Oct 21 15:26:30 AEDT 2021
This is an automated email from the git hooks/post-receive script.
dtucker pushed a commit to branch master
in repository openssh.
commit 5a7a4687507d057f9b5e7497f3d3f82e64753c02
Author: Darren Tucker <dtucker at dtucker.net>
Date: Thu Oct 21 15:00:53 2021 +1100
Build with -Werror on most recent gcc and clang.
---
.github/configs | 13 +++++++++++++
.github/workflows/c-cpp.yml | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/.github/configs b/.github/configs
index 0a1480d5..90401c9d 100755
--- a/.github/configs
+++ b/.github/configs
@@ -29,6 +29,19 @@ case "$config" in
LIBCRYPTOFLAGS="--without-openssl"
TEST_TARGET=t-exec
;;
+ clang-12-Werror)
+ CC="clang-12"
+ # clang's implicit-fallthrough requires that the code be annotated with
+ # __attribute__((fallthrough)) and does not understand /* FALLTHROUGH */
+ CFLAGS="-Wall -Wextra -O2 -Wno-error=implicit-fallthrough"
+ CONFIGFLAGS="--with-pam --with-Werror"
+ ;;
+ gcc-11-Werror)
+ CC="gcc"
+ # -Wnoformat-truncation in gcc 7.3.1 20180130 fails on fmt_scaled
+ CFLAGS="-Wall -Wextra -Wno-format-truncation -O2 -Wimplicit-fallthrough=4"
+ CONFIGFLAGS="--with-pam --with-Werror"
+ ;;
clang*|gcc*)
CC="$config"
;;
diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml
index 530922f8..f3f897dc 100644
--- a/.github/workflows/c-cpp.yml
+++ b/.github/workflows/c-cpp.yml
@@ -29,11 +29,11 @@ jobs:
- { os: ubuntu-20.04, configs: clang-9 }
- { os: ubuntu-20.04, configs: clang-10 }
- { os: ubuntu-20.04, configs: clang-11 }
- - { os: ubuntu-20.04, configs: clang-12 }
+ - { os: ubuntu-20.04, configs: clang-12-Werror }
- { os: ubuntu-20.04, configs: gcc-7 }
- { os: ubuntu-20.04, configs: gcc-8 }
- { os: ubuntu-20.04, configs: gcc-10 }
- - { os: ubuntu-20.04, configs: gcc-11 }
+ - { os: ubuntu-20.04, configs: gcc-11-Werror }
- { os: ubuntu-20.04, configs: pam }
- { os: ubuntu-20.04, configs: kitchensink }
- { os: ubuntu-20.04, configs: hardenedmalloc }
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list