projects/aports·blob master · refs

161 lines · 5.7 KiB

1diff -Nurp a/src/CMakeLists.txt b/src/CMakeLists.txt
2--- a/src/CMakeLists.txt 2025-09-18 19:36:02.325155787 +0000
3+++ b/src/CMakeLists.txt 2025-09-18 19:36:02.339155974 +0000
4@@ -432,7 +432,6 @@ set(libcommon_files
5 ${CMAKE_BINARY_DIR}/src/include/ceph_ver.h
6 ceph_ver.c
7 global/global_context.cc
8- xxHash/xxhash.c
9 common/error_code.cc
10 common/tracer.cc
11 log/Log.cc
12@@ -566,6 +565,8 @@ add_library(common STATIC ${ceph_common_
13 target_link_libraries(common
14 ${ceph_common_deps}
15 legacy-option-headers)
16+pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
17+target_link_libraries(common-objs PkgConfig::XXHASH)
18 if(WITH_JAEGER)
19 add_dependencies(common jaeger_base)
20 endif()
21diff -Nurp a/src/common/Checksummer.h b/src/common/Checksummer.h
22--- a/src/common/Checksummer.h 2025-09-18 19:36:02.326155800 +0000
23+++ b/src/common/Checksummer.h 2025-09-18 19:36:02.340155988 +0000
24@@ -8,7 +8,7 @@
25 #include "include/byteorder.h"
26 #include "include/ceph_assert.h"
27
28-#include "xxHash/xxhash.h"
29+#include "xxhash.h"
30
31 class Checksummer {
32 public:
33diff -Nurp a/src/crimson/CMakeLists.txt b/src/crimson/CMakeLists.txt
34--- a/src/crimson/CMakeLists.txt 2025-09-18 19:36:02.328155827 +0000
35+++ b/src/crimson/CMakeLists.txt 2025-09-18 19:36:02.340155988 +0000
36@@ -117,7 +117,6 @@ add_library(crimson-common STATIC
37 ${PROJECT_SOURCE_DIR}/src/osd/OSDMap.cc
38 ${PROJECT_SOURCE_DIR}/src/osd/PGPeeringEvent.cc
39 ${PROJECT_SOURCE_DIR}/src/common/scrub_types.cc
40- ${PROJECT_SOURCE_DIR}/src/xxHash/xxhash.c
41 ${crimson_common_srcs}
42 $<TARGET_OBJECTS:common_mountcephfs_objs>
43 $<TARGET_OBJECTS:common-options-objs>)
44@@ -141,10 +140,12 @@ if(NOT WITH_SYSTEM_BOOST)
45 list(APPEND crimson_common_deps ${ZLIB_LIBRARIES})
46 endif()
47
48+pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
49 target_link_libraries(crimson-common
50 PUBLIC
51 ${crimson_common_public_deps}
52 PRIVATE
53+ PkgConfig::XXHASH
54 crc32 arch
55 ${crimson_common_deps}
56 OpenSSL::Crypto)
57diff -Nurp a/src/os/CMakeLists.txt b/src/os/CMakeLists.txt
58--- a/src/os/CMakeLists.txt 2025-09-18 19:36:02.330155854 +0000
59+++ b/src/os/CMakeLists.txt 2025-09-18 19:36:02.341156001 +0000
60@@ -42,10 +42,12 @@ if(HAVE_LIBXFS)
61 fs/XFS.cc)
62 endif()
63
64+pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
65 add_library(os STATIC ${libos_srcs})
66 target_link_libraries(os
67 legacy-option-headers
68 blk
69+ PkgConfig::XXHASH
70 ${FMT_LIB})
71
72 target_compile_definitions(os PRIVATE -DWITH_KSTORE)
73diff -Nurp a/src/rgw/CMakeLists.txt b/src/rgw/CMakeLists.txt
74--- a/src/rgw/CMakeLists.txt 2025-09-18 19:38:45.252336840 +0000
75+++ b/src/rgw/CMakeLists.txt 2025-09-18 19:58:12.349978391 +0000
76@@ -288,6 +288,7 @@ if(COMPILER_SUPPORTS_WARN_IMPLICIT_CONST
77 HAVE_WARN_IMPLICIT_CONST_INT_FLOAT_CONVERSION)
78 endif()
79
80+pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
81 target_link_libraries(rgw_common
82 PRIVATE
83 legacy-option-headers
84@@ -315,6 +316,7 @@ target_link_libraries(rgw_common
85 ${ARROW_FLIGHT_LIBRARIES}
86 ${LMDB_LIBRARIES}
87 PUBLIC
88+ PkgConfig::XXHASH
89 ${LUA_LIBRARIES}
90 RapidJSON::RapidJSON
91 Boost::context
92diff -Nurp a/src/test/neorados/read_operations.cc b/src/test/neorados/read_operations.cc
93--- a/src/test/neorados/read_operations.cc 2025-10-10 05:15:04.593294866 +0000
94+++ b/src/test/neorados/read_operations.cc 2025-10-10 05:15:20.735502210 +0000
95@@ -26,7 +26,7 @@
96 #include <boost/system/error_code.hpp>
97 #include <boost/system/errc.hpp>
98
99-#include <xxHash/xxhash.h>
100+#include <xxhash.h>
101
102 #include "include/neorados/RADOS.hpp"
103 #include "include/rbd/features.h" // for RBD_FEATURES_ALL
104diff -Nurp a/src/test/librados/CMakeLists.txt b/src/test/librados/CMakeLists.txt
105--- a/src/test/librados/CMakeLists.txt 2025-10-10 13:05:38.345172398 +0000
106+++ b/src/test/librados/CMakeLists.txt 2025-10-10 13:20:16.324410133 +0000
107@@ -96,16 +96,17 @@ add_executable(ceph_test_rados_api_cls
108 target_link_libraries(ceph_test_rados_api_cls
109 librados ${UNITTEST_LIBS} radostest-cxx)
110
111+pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
112 add_executable(ceph_test_rados_api_misc
113 misc.cc
114 $<TARGET_OBJECTS:unit-main>)
115 target_link_libraries(ceph_test_rados_api_misc
116- librados global ${UNITTEST_LIBS} radostest)
117+ PkgConfig::XXHASH librados global ${UNITTEST_LIBS} radostest)
118 add_executable(ceph_test_rados_api_misc_pp
119 misc_cxx.cc
120 $<TARGET_OBJECTS:unit-main>)
121 target_link_libraries(ceph_test_rados_api_misc_pp
122- librados global ${UNITTEST_LIBS} radostest-cxx)
123+ PkgConfig::XXHASH librados global ${UNITTEST_LIBS} radostest-cxx)
124
125 add_executable(ceph_test_rados_api_lock
126 lock.cc)
127diff -Nurp a/src/test/neorados/CMakeLists.txt b/src/test/neorados/CMakeLists.txt
128--- a/src/test/neorados/CMakeLists.txt 2025-10-10 12:35:51.950329587 +0000
129+++ b/src/test/neorados/CMakeLists.txt 2025-10-10 13:03:33.795578646 +0000
130@@ -77,7 +77,9 @@ install(TARGETS
131 add_executable(ceph_test_neorados_read_operations
132 read_operations.cc
133 )
134+ pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
135 target_link_libraries(ceph_test_neorados_read_operations
136+ PkgConfig::XXHASH
137 libneorados
138 ${BLKID_LIBRARIES}
139 ${CMAKE_DL_LIBS}
140diff -Nurp a/src/test/CMakeLists.txt b/src/test/CMakeLists.txt
141diff -Nurp a/src/test/CMakeLists.txt b/src/test/CMakeLists.txt
142--- a/src/test/CMakeLists.txt 2025-10-10 14:50:43.419289886 +0000
143+++ b/src/test/CMakeLists.txt 2025-10-10 15:05:24.036141003 +0000
144@@ -316,6 +316,7 @@ add_executable(ceph_test_librgw_file_gp
145 librgw_file_gp.cc
146 )
147 target_link_libraries(ceph_test_librgw_file_gp
148+ PkgConfig::XXHASH
149 rgw
150 librados
151 ceph-common
152@@ -349,7 +350,9 @@ install(TARGETS ceph_test_librgw_file_nf
153 add_executable(ceph_test_librgw_file_aw
154 librgw_file_aw.cc
155 )
156+pkg_check_modules(XXHASH IMPORTED_TARGET libxxhash)
157 target_link_libraries(ceph_test_librgw_file_aw
158+ PkgConfig::XXHASH
159 rgw
160 librados
161 ceph-common