From 88845c2ae23e9ee5482506e582fe881ec0d4d934 Mon Sep 17 00:00:00 2001 From: Matan Breizman Date: Mon, 17 Feb 2025 07:39:19 +0000 Subject: [PATCH] src/CMakeLists.txt: add -Wno-vla-cxx-extension to clang The following warning of: ``` error: variable length arrays in C++ are a Clang extension [-Werror,-Wvla-cxx-extension] ``` is enabled by default in clang 18 and above. Disable it in our builds due to large anmount of warnings. We can revert this once we handle some of the warnings in future PRs. Signed-off-by: Matan Breizman --- src/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index a32600d4e06..eea961a23f3 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -168,7 +168,8 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL Clang) -Wno-gnu-designator -Wno-missing-braces -Wno-parentheses - -Wno-deprecated-register) + -Wno-deprecated-register + -Wno-vla-cxx-extension) if(FREEBSD) # Need to use the GNU binutils linker to get versioning right. string(APPEND CMAKE_EXE_LINKER_FLAGS " -fuse-ld=/usr/local/bin/ld -Wno-unused-command-line-argument") -- 2.39.5