]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
test/crimson/seastore: add missing crimson::gtest to link libraries 68217/head
authorKefu Chai <k.chai@proxmox.com>
Sun, 5 Apr 2026 22:52:45 +0000 (06:52 +0800)
committerKefu Chai <k.chai@proxmox.com>
Sun, 5 Apr 2026 22:57:14 +0000 (06:57 +0800)
unittest-transaction-manager, unittest-omap-manager,
unittest-btree-lba-manager, and unittest-seastore all include
gtest_seastar.cc but were not explicitly linking against crimson::gtest.
This worked previously because gtest symbols were pulled in transitively,
but with gcc-toolset-13 and LTO the transitive dependency is no longer
satisfied, producing undefined reference errors for testing::Message,
testing::Test, testing::AssertionSuccess, etc.

Fix by linking these tests against crimson::gtest

Signed-off-by: Kefu Chai <k.chai@proxmox.com>
src/test/crimson/seastore/CMakeLists.txt

index 1ef1d05e1ee5d8a6a754812612e02e3c472e6fc2..cbbbfafd1d38412a43da9f199b3d3ee1ed93fd81 100644 (file)
@@ -13,6 +13,7 @@ add_executable(unittest-transaction-manager
   --memory 256M --smp 1)
 target_link_libraries(
   unittest-transaction-manager
+  crimson::gtest
   ${CMAKE_DL_LIBS}
   crimson-seastore)
 avoid_asan_uar_slowdown(unittest-transaction-manager)
@@ -24,6 +25,7 @@ add_ceph_unittest(unittest-omap-manager
   --memory 256M --smp 1)
 target_link_libraries(
   unittest-omap-manager
+  crimson::gtest
   ${CMAKE_DL_LIBS}
   crimson-seastore)
 avoid_asan_uar_slowdown(unittest-omap-manager)
@@ -35,6 +37,7 @@ add_ceph_unittest(unittest-btree-lba-manager
   --memory 256M --smp 1)
 target_link_libraries(
   unittest-btree-lba-manager
+  crimson::gtest
   ${CMAKE_DL_LIBS}
   crimson-seastore)
 
@@ -91,6 +94,7 @@ add_ceph_unittest(unittest-seastore
   --memory 256M --smp 1)
 target_link_libraries(
   unittest-seastore
+  crimson::gtest
   ${CMAKE_DL_LIBS}
   crimson-seastore
   crimson-common)