|
@@ -11,6 +11,9 @@ option(DOUBLE_PRECISION "Use double precision math" OFF)
|
|
# When turning this option on, the library will be compiled with debug symbols
|
|
# When turning this option on, the library will be compiled with debug symbols
|
|
option(GENERATE_DEBUG_SYMBOLS "Generate debug symbols" ON)
|
|
option(GENERATE_DEBUG_SYMBOLS "Generate debug symbols" ON)
|
|
|
|
|
|
|
|
+# Which type of debug symbols to generate, e.g. using source-map when compiling with emscripten makes compilation a lot faster
|
|
|
|
+set(JPH_DEBUG_SYMBOL_FORMAT "" CACHE STRING "Which type of debug symbols to generate")
|
|
|
|
+
|
|
# When turning this option on, the library will override the default CMAKE_CXX_FLAGS_DEBUG/RELEASE values, otherwise they will use the platform defaults
|
|
# When turning this option on, the library will override the default CMAKE_CXX_FLAGS_DEBUG/RELEASE values, otherwise they will use the platform defaults
|
|
option(OVERRIDE_CXX_FLAGS "Override CMAKE_CXX_FLAGS_DEBUG/RELEASE" ON)
|
|
option(OVERRIDE_CXX_FLAGS "Override CMAKE_CXX_FLAGS_DEBUG/RELEASE" ON)
|
|
|
|
|
|
@@ -191,7 +194,7 @@ else()
|
|
|
|
|
|
# Optionally generate debug symbols
|
|
# Optionally generate debug symbols
|
|
if (GENERATE_DEBUG_SYMBOLS)
|
|
if (GENERATE_DEBUG_SYMBOLS)
|
|
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g")
|
|
|
|
|
|
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g${JPH_DEBUG_SYMBOL_FORMAT}")
|
|
endif()
|
|
endif()
|
|
|
|
|
|
if (NOT CPP_RTTI_ENABLED)
|
|
if (NOT CPP_RTTI_ENABLED)
|