From ed18ad510192c7aa2b1ab66f0d2e67f6bdcbc531 Mon Sep 17 00:00:00 2001 From: Johannes Schmidt Date: Thu, 26 Feb 2026 11:45:06 +0100 Subject: [PATCH] Disable -Wregister for amazonlinux:2 in CI amazonlinux:2 has a really old GNU bison version (3.0.4), which emits `register` storage specifiers in its generated C code, which any standard starting with C99 doesn't allow anymore. --- .github/workflows/linux.bash | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/linux.bash b/.github/workflows/linux.bash index 9cf3d1135..20bd7a653 100755 --- a/.github/workflows/linux.bash +++ b/.github/workflows/linux.bash @@ -13,6 +13,12 @@ SCL_ENABLE_GCC=() WARN_FLAGS="-Wall -Wextra -Wno-template-id-cdtor -Wno-stringop-overflow" case "$DISTRO" in + amazonlinux:2) + # amazonlinux:2 has a really old GNU bison (3.0.4), which still emits register storage + # specifiers, that even the only slightly more modern compiler warns that C++17 does not + # allow (duh). + WARN_FLAGS="${WARN_FLAGS} -Wno-register" + ;; debian:11) # -Wattributes neededs to be disabled to not get warnings in old compilers about not-yet # understood attributes, like [[gnu::no_dangling]] on debian:11.