Jelajahi Sumber

Build: Add -fsized-deallocation to global CXXFLAGS

This is enabled by default for GCC (>=C++14) but apparently not for
Clang, which has been causing CLion to get confused about kernel code.
Andreas Kling 4 tahun lalu
induk
melakukan
2362ebf483
1 mengubah file dengan 1 tambahan dan 0 penghapusan
  1. 1 0
      CMakeLists.txt

+ 1 - 0
CMakeLists.txt

@@ -101,6 +101,7 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON)
 set(CMAKE_CXX_EXTENSIONS OFF)
 
 add_compile_options(-Wno-literal-suffix)
+add_compile_options(-fsized-deallocation)
 if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
     add_compile_options(-Wno-literal-suffix)
 elseif ("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang$")