diff --git a/CMakeLists.txt b/CMakeLists.txt
index 992d7115d038dd6838aa0a584409a58d562b6816..3823f22eb6d6709916a8330d76fd03397b03774d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -79,7 +79,7 @@ if (MSVC)
 else()
     # lots of warnings and all warnings as errors, allow for checking code coverage
     target_compile_options(bgk-lib PUBLIC
-        -Wall -Wextra -Wshadow -Wconversion -Wpedantic -Werror -Wno-unused-but-set-variable
+        -Wall -Wextra -Wshadow -Wconversion -Wpedantic -Werror -Wno-unused-but-set-variable -Wno-unused-variable
         $<$<BOOL:${TEST_COVERAGE}>:--coverage -fprofile-abs-path>
     )