Skip to content

Commit

Permalink
CMake: Provide build flag to enable compile time tracing.
Browse files Browse the repository at this point in the history
  • Loading branch information
tritao authored and chennes committed Jan 29, 2025
1 parent ade3ae0 commit 1e05c59
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cMake/FreeCAD_Helpers/CompilerChecksAndSetups.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,11 @@ macro(CompilerChecksAndSetups)
if(BUILD_USE_LIBCXX)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
endif()

if(BUILD_ENABLE_TIME_TRACE)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -ftime-trace")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftime-trace")
endif()
endif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_CLANGXX)

if(CMAKE_COMPILER_IS_CLANGXX)
Expand Down

0 comments on commit 1e05c59

Please sign in to comment.