Build: New CMake option -DBUILD_TIME_ANALYSIS=1 for clang (enables detailed compile time statistics that can be later viewed with ClangBuildAnalyzer)

This commit is contained in:
Shauren
2022-02-11 22:25:49 +01:00
parent fe35971d2f
commit bd4e5b6d0b

View File

@@ -125,6 +125,14 @@ if(TSAN)
message(STATUS "Clang: Enabled Thread Sanitizer TSan")
endif()
if(BUILD_TIME_ANALYSIS)
target_compile_options(trinity-compile-option-interface
INTERFACE
-ftime-trace)
message(STATUS "Clang: Enabled build time analysis (-ftime-trace)")
endif()
# -Wno-narrowing needed to suppress a warning in g3d
# -Wno-deprecated-register is needed to suppress 185 gsoap warnings on Unix systems.
# -Wno-deprecated-copy needed to suppress a warning in g3d