Skip to content

Commit

Permalink
Merge pull request #1917 from borglab/gperftools-switch
Browse files Browse the repository at this point in the history
  • Loading branch information
varunagrawal authored Dec 6, 2024
2 parents bb5cfb2 + c00de92 commit 6281112
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions cmake/FindGooglePerfTools.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,5 @@ MARK_AS_ADVANCED(
GPERFTOOLS_TCMALLOC
GPERFTOOLS_PROFILER
)

option(GTSAM_ENABLE_GPERFTOOLS "Enable/Disable Gperftools" OFF)
2 changes: 1 addition & 1 deletion gtsam/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ if (GTSAM_USE_EIGEN_MKL)
target_include_directories(gtsam PUBLIC ${MKL_INCLUDE_DIR})
endif()

if (GPERFTOOLS_FOUND)
if (GTSAM_ENABLE_GPERFTOOLS AND GPERFTOOLS_FOUND)
target_link_libraries(gtsam PRIVATE ${GPERFTOOLS_TCMALLOC} ${GPERFTOOLS_PROFILER})
endif()

Expand Down

0 comments on commit 6281112

Please sign in to comment.