Skip to content

Commit

Permalink
cmake: add boost-system to ALLOC_LIBS
Browse files Browse the repository at this point in the history
perfglue/heap_profiler.cc is referncing boost-system somehow, and
this file is compiled when we are using tcmalloc, so added it to
ALLOC_LIBS along with tcmalloc.

Signed-off-by: Kefu Chai <kchai@redhat.com>
  • Loading branch information
tchaikov committed Feb 4, 2016
1 parent 0e42ee9 commit 1cd6e87
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/CMakeLists.txt
Expand Up @@ -129,7 +129,7 @@ endif(HAVE_XIO)

# sort out which allocator to use
if(Tcmalloc_FOUND)
set(ALLOC_LIBS tcmalloc)
set(ALLOC_LIBS tcmalloc ${Boost_SYSTEM_LIBRARY})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-builtin-malloc -fno-builtin-calloc -fno-builtin-realloc -fno-builtin-free")
set(TCMALLOC_srcs perfglue/heap_profiler.cc)
elseif(NOT Tcmalloc_FOUND AND JEMALLOC_FOUND)
Expand Down
2 changes: 1 addition & 1 deletion src/test/CMakeLists.txt
Expand Up @@ -2096,7 +2096,7 @@ add_executable(test_rados_api_tier
set_target_properties(test_rados_api_tier PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(test_rados_api_tier
global librados ${UNITTEST_LIBS} ${ALLOC_LIBS} ${Boost_SYSTEM_LIBRARY} radostest)
global librados ${UNITTEST_LIBS} ${ALLOC_LIBS} radostest)

add_executable(test_rados_api_snapshots
librados/snapshots.cc
Expand Down

0 comments on commit 1cd6e87

Please sign in to comment.