Skip to content

Commit

Permalink
cmake: link libcommon against pthread
Browse files Browse the repository at this point in the history
as Thread.cc lives in libcommon, and global is not using libpthread
directly. so moving libpthread linkage from libglobal to libcommon.

Signed-off-by: Kefu Chai <kchai@redhat.com>
  • Loading branch information
tchaikov committed Jul 29, 2016
1 parent 8bf5cd1 commit a27bbaa
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
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ add_library(common STATIC ${libcommon_files}
$<TARGET_OBJECTS:common_mountcephfs_objs>)
target_link_libraries(common json_spirit erasure_code rt resolv
${Boost_LIBRARIES} ${BLKID_LIBRARIES} ${Backtrace_LIBRARIES}
${CRYPTO_LIBS} ${CMAKE_DL_LIBS})
${CRYPTO_LIBS} ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS})

set_source_files_properties(${CMAKE_SOURCE_DIR}/src/ceph_ver.c
${CMAKE_SOURCE_DIR}/src/common/version.cc
Expand Down
2 changes: 1 addition & 1 deletion src/global/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ set(global_common_files
add_library(global_common_objs OBJECT ${global_common_files})
add_library(global STATIC ${libglobal_srcs}
$<TARGET_OBJECTS:global_common_objs>)
target_link_libraries(global common ${CMAKE_THREAD_LIBS_INIT} ${EXTRALIBS})
target_link_libraries(global common ${EXTRALIBS})

0 comments on commit a27bbaa

Please sign in to comment.