]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cmake: only link against necessary libs
authorKefu Chai <kchai@redhat.com>
Mon, 2 Sep 2019 08:07:49 +0000 (16:07 +0800)
committerKefu Chai <kchai@redhat.com>
Mon, 2 Sep 2019 08:32:43 +0000 (16:32 +0800)
some executables like ceph_test_mon_memory_target does not link against
gtest or gmock, so no need to link agains them.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/test/mon/CMakeLists.txt

index 79870b6c7813722c511893d77c50d0be597f70ea..b206f27e52929c4129831fcc8b3a85c6e13cf3c2 100644 (file)
@@ -42,25 +42,20 @@ target_link_libraries(unittest_mon_montypes mon global)
 
 # ceph_test_mon_memory_target
 add_executable(ceph_test_mon_memory_target
-  test_mon_memory_target.cc
-  )
-target_link_libraries(ceph_test_mon_memory_target ${UNITTEST_LIBS} Boost::system)
+  test_mon_memory_target.cc)
+target_link_libraries(ceph_test_mon_memory_target Boost::system Threads::Threads)
 install(TARGETS ceph_test_mon_memory_target
   DESTINATION ${CMAKE_INSTALL_BINDIR})
 
 # ceph_test_mon_log_rss_usage
 add_executable(ceph_test_log_rss_usage
-  test_log_rss_usage.cc
-  )
-target_link_libraries(ceph_test_log_rss_usage ${UNITTEST_LIBS})
+  test_log_rss_usage.cc)
 install(TARGETS ceph_test_log_rss_usage
   DESTINATION ${CMAKE_INSTALL_BINDIR})
 
 # ceph_test_mon_rss_usage
 add_executable(ceph_test_mon_rss_usage
-  test_mon_rss_usage.cc
-  )
-target_link_libraries(ceph_test_mon_rss_usage ${UNITTEST_LIBS})
+  test_mon_rss_usage.cc)
 install(TARGETS ceph_test_mon_rss_usage
   DESTINATION ${CMAKE_INSTALL_BINDIR})