@@ -13,31 +13,29 @@ set_property(CACHE RTS_DEBUG_PROFILE PROPERTY STRINGS DEFAULT ON OFF)
13
13
option (RTS_DEBUG_INCLUDE_DEBUG_LOG_IN_CRC_LOG "Include normal debug log in crc log" OFF )
14
14
15
15
16
- add_feature_info(DebugLogging RTS_DEBUG_LOGGING "Build with Debug Logging" )
17
- add_feature_info(DebugCrashing RTS_DEBUG_CRASHING "Build with Debug Crashing" )
18
- add_feature_info(DebugStacktrace RTS_DEBUG_STACKTRACE "Build with Debug Stacktracing" )
19
- add_feature_info(DebugProfile RTS_DEBUG_PROFILE "Build with Debug Profiling" )
20
- add_feature_info(DebugIncludeDebugLogInCrcLog RTS_DEBUG_INCLUDE_DEBUG_LOG_IN_CRC_LOG "Build with Debug Logging in CRC log" )
21
-
22
-
23
16
# Helper macro that handles DEFAULT ON OFF options
24
- macro (define_debug_option OptionName OptionEnabledCompileDef OptionDisabledCompileDef)
17
+ macro (define_debug_option OptionName OptionEnabledCompileDef OptionDisabledCompileDef FeatureInfoName FeatureInfoDescription )
25
18
if (${OptionName} STREQUAL "DEFAULT" )
26
19
# Does nothing
27
20
elseif (${OptionName} STREQUAL "ON" )
28
21
target_compile_definitions (core_config INTERFACE ${OptionEnabledCompileDef} =1)
22
+ add_feature_info(${FeatureInfoName} TRUE ${FeatureInfoDescription} )
29
23
elseif (${OptionName} STREQUAL "OFF" )
30
24
target_compile_definitions (core_config INTERFACE ${OptionDisabledCompileDef} =1)
25
+ add_feature_info(${FeatureInfoName} FALSE ${FeatureInfoDescription} )
31
26
else ()
32
27
message (FATAL_ERROR "Unhandled option" )
33
28
endif ()
34
29
endmacro ()
35
30
36
31
37
- define_debug_option(RTS_DEBUG_LOGGING DEBUG_LOGGING DISABLE_DEBUG_LOGGING )
38
- define_debug_option(RTS_DEBUG_CRASHING DEBUG_CRASHING DISABLE_DEBUG_CRASHING )
39
- define_debug_option(RTS_DEBUG_STACKTRACE DEBUG_STACKTRACE DISABLE_DEBUG_STACKTRACE)
40
- define_debug_option(RTS_DEBUG_PROFILE DEBUG_PROFILE DISABLE_DEBUG_PROFILE )
32
+ define_debug_option(RTS_DEBUG_LOGGING DEBUG_LOGGING DISABLE_DEBUG_LOGGING DebugLogging "Build with Debug Logging" )
33
+ define_debug_option(RTS_DEBUG_CRASHING DEBUG_CRASHING DISABLE_DEBUG_CRASHING DebugCrashing "Build with Debug Crashing" )
34
+ define_debug_option(RTS_DEBUG_STACKTRACE DEBUG_STACKTRACE DISABLE_DEBUG_STACKTRACE DebugStacktrace "Build with Debug Stacktracing" )
35
+ define_debug_option(RTS_DEBUG_PROFILE DEBUG_PROFILE DISABLE_DEBUG_PROFILE DebugProfile "Build with Debug Profiling" )
36
+
37
+ add_feature_info(DebugIncludeDebugLogInCrcLog RTS_DEBUG_INCLUDE_DEBUG_LOG_IN_CRC_LOG "Build with Debug Logging in CRC log" )
38
+
41
39
42
40
if (RTS_DEBUG_INCLUDE_DEBUG_LOG_IN_CRC_LOG)
43
41
target_compile_definitions (core_config INTERFACE INCLUDE_DEBUG_LOG_IN_CRC_LOG)
0 commit comments