diff --git a/Kernel/CMakeLists.txt b/Kernel/CMakeLists.txt index 31a4c9c6d9..f77281137c 100644 --- a/Kernel/CMakeLists.txt +++ b/Kernel/CMakeLists.txt @@ -283,9 +283,9 @@ if (NOT ${CMAKE_HOST_SYSTEM_NAME} MATCHES SerenityOS) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -nostdlib -nostdinc -nostdinc++") endif() -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=undefined") -endif() +# Kernel Undefined Behavior Sanitizer (KUBSAN) +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=undefined") + # Kernel Address Sanitize (KASAN) implementation is still a work in progress, this option # is not currently meant to be used, besides when developing Kernel ASAN support. #