diff --git a/flags.cmake b/flags.cmake index 07ecfe486f..f260682fe7 100644 --- a/flags.cmake +++ b/flags.cmake @@ -1,4 +1,9 @@ option(SPINE_SANITIZE "Build with sanitization" OFF) +option(SPINE_SET_COMPILER_FLAGS "Set compiler flags" ON) + +if (NOT SPINE_SET_COMPILER_FLAGS) + return(); +endif() if(MSVC) message("MSCV detected") @@ -11,4 +16,4 @@ else() set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=address -fsanitize=undefined") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address -fsanitize=undefined") endif() -endif() \ No newline at end of file +endif()