5104bd
--- ceph-17.1.0/src/rgw/store/dbstore/CMakeLists.txt.orig	2022-02-28 14:11:49.987077811 -0500
5104bd
+++ ceph-17.1.0/src/rgw/store/dbstore/CMakeLists.txt	2022-02-28 14:12:19.576542037 -0500
5104bd
@@ -38,6 +38,7 @@
5104bd
 
5104bd
 # add pthread library
5104bd
 set (CMAKE_LINK_LIBRARIES ${CMAKE_LINK_LIBRARIES} pthread)
5104bd
+set (CMAKE_LINK_LIBRARIES ${CMAKE_LINK_LIBRARIES} global)
5104bd
 
5104bd
 find_package(gtest QUIET)
5104bd
 if(WITH_TESTS)
5104bd
--- ceph-17.1.0/src/rgw/CMakeLists.txt.orig	2022-02-28 16:21:08.430487482 -0500
5104bd
+++ ceph-17.1.0/src/rgw/CMakeLists.txt	2022-02-28 16:25:01.893245213 -0500
5104bd
@@ -254,10 +254,6 @@
5104bd
   target_link_libraries(rgw_common PUBLIC ${jaeger_base})
5104bd
 endif()
5104bd
 
5104bd
-if(WITH_RADOSGW_DBSTORE)
5104bd
-  target_link_libraries(rgw_common PRIVATE global dbstore)
5104bd
-endif()
5104bd
-
5104bd
 set(rgw_a_srcs
5104bd
   rgw_auth_keystone.cc
5104bd
   rgw_client_io.cc
5104bd
@@ -308,8 +304,13 @@
5104bd
   find_package(RDKafka 0.9.2 REQUIRED)
5104bd
 endif()
5104bd
 
5104bd
+if(WITH_RADOSGW_DBSTORE)
5104bd
+set (DBSTORE_LIB dbstore)
5104bd
+endif()
5104bd
+
5104bd
 target_link_libraries(rgw_a
5104bd
   PRIVATE
5104bd
+    ${DBSTORE_LIB}
5104bd
     common_utf8 global
5104bd
     ${CRYPTO_LIBS}
5104bd
     ${LUA_LIBRARIES}