cmake: link tests against static librados

Fixes: http://tracker.ceph.com/issues/17260
Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2016-10-20 15:46:09 +08:00
parent 8362c5f1cf
commit 711b394481

View File

@ -13,7 +13,7 @@ add_executable(ceph_test_rados_api_cmd
set_target_properties(ceph_test_rados_api_cmd PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_cmd
librados global ${UNITTEST_LIBS} radostest)
rados_a global ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_io
add_executable(ceph_test_rados_api_io
@ -58,7 +58,7 @@ add_executable(ceph_test_rados_api_list
set_target_properties(ceph_test_rados_api_list PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_list
librados global ${UNITTEST_LIBS} radostest)
rados_a global ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_nlist
add_executable(ceph_test_rados_api_nlist
@ -67,7 +67,7 @@ add_executable(ceph_test_rados_api_nlist
set_target_properties(ceph_test_rados_api_nlist PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_nlist
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_pool
add_executable(ceph_test_rados_api_pool
@ -77,7 +77,7 @@ set_target_properties(ceph_test_rados_api_pool PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS}
)
target_link_libraries(ceph_test_rados_api_pool
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_stat
add_executable(ceph_test_rados_api_stat
@ -86,7 +86,7 @@ add_executable(ceph_test_rados_api_stat
set_target_properties(ceph_test_rados_api_stat PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_stat
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_watch_notify
add_executable(ceph_test_rados_api_watch_notify
@ -95,7 +95,7 @@ add_executable(ceph_test_rados_api_watch_notify
set_target_properties(ceph_test_rados_api_watch_notify PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_watch_notify
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_cls
add_executable(ceph_test_rados_api_cls
@ -104,7 +104,7 @@ add_executable(ceph_test_rados_api_cls
set_target_properties(ceph_test_rados_api_cls PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_cls
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_misc
add_executable(ceph_test_rados_api_misc
@ -113,7 +113,7 @@ add_executable(ceph_test_rados_api_misc
set_target_properties(ceph_test_rados_api_misc PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_misc
librados global ${UNITTEST_LIBS} radostest)
rados_a global ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_lock
add_executable(ceph_test_rados_api_lock
@ -122,7 +122,7 @@ add_executable(ceph_test_rados_api_lock
set_target_properties(ceph_test_rados_api_lock PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_lock
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
# ceph_test_rados_api_tier
add_executable(ceph_test_rados_api_tier
@ -131,7 +131,7 @@ add_executable(ceph_test_rados_api_tier
set_target_properties(ceph_test_rados_api_tier PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_tier
global librados ${UNITTEST_LIBS} ${Boost_SYSTEM_LIBRARY} radostest)
global rados_a ${UNITTEST_LIBS} ${Boost_SYSTEM_LIBRARY} radostest)
# ceph_test_rados_api_snapshots
add_executable(ceph_test_rados_api_snapshots
@ -140,7 +140,7 @@ add_executable(ceph_test_rados_api_snapshots
set_target_properties(ceph_test_rados_api_snapshots PROPERTIES COMPILE_FLAGS
${UNITTEST_CXX_FLAGS})
target_link_libraries(ceph_test_rados_api_snapshots
librados ${UNITTEST_LIBS} radostest)
rados_a ${UNITTEST_LIBS} radostest)
install(TARGETS
ceph_test_rados_api_aio