On linux cmake don’t generate debug symbols in debug config -DCMAKE_BUILD_TYPE=Debug
fix:
[code]@@ -385,12 +385,12 @@ else ()
set (CMAKE_CXX_FLAGS_RELWITHDEBINFO “-O2 -g -DNDEBUG”)
# Reduce GCC optimization level from -O3 to -O2 for stability in RELEASE build configuration
set (CMAKE_C_FLAGS_RELEASE “-O2 -DNDEBUG”)
set (CMAKE_CXX_FLAGS_RELEASE “-O2 -DNDEBUG”)
endif ()
-
set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DDEBUG -D_DEBUG")
-
set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG -D_DEBUG")
-
set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -g -DDEBUG -D_DEBUG")
-
endif ()set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -g -DDEBUG -D_DEBUG")
if (CMAKE_CXX_COMPILER_ID STREQUAL Clang)
if (CMAKE_GENERATOR STREQUAL Ninja)
set (CMAKE_C_FLAGS “${CMAKE_C_FLAGS} -fcolor-diagnostics”)
set (CMAKE_CXX_FLAGS “${CMAKE_CXX_FLAGS} -fcolor-diagnostics”)
[/code]