]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cmake: promote uring package search to top-level
authorPatrick Donnelly <pdonnell@redhat.com>
Tue, 17 Oct 2023 16:59:41 +0000 (12:59 -0400)
committerPatrick Donnelly <pdonnell@redhat.com>
Fri, 20 Oct 2023 13:41:56 +0000 (09:41 -0400)
For use by multiple projects, rocksdb in particular.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit 3438de58f2af599901a19cf984e2e7cb1e9f6944)

CMakeLists.txt
src/blk/CMakeLists.txt

index 91f4923c5791f2858e2a31f8fdf7ea8d0872b5a2..7f049ba94e6ed53448e2b92ec4b5fa0d588dc0d0 100644 (file)
@@ -247,6 +247,15 @@ set(HAVE_LIBURING ${WITH_LIBURING})
 CMAKE_DEPENDENT_OPTION(WITH_SYSTEM_LIBURING "Require and build with system liburing" OFF
   "HAVE_LIBAIO;WITH_BLUESTORE" OFF)
 
+if(WITH_LIBURING)
+  if(WITH_SYSTEM_LIBURING)
+    find_package(uring REQUIRED)
+  else()
+    include(Builduring)
+    build_uring()
+  endif()
+endif()
+
 CMAKE_DEPENDENT_OPTION(WITH_BLUESTORE_PMEM "Enable PMDK libraries" OFF
   "WITH_BLUESTORE" OFF)
 if(WITH_BLUESTORE_PMEM)
index 288955dd054753e13a32cb7e05ecd98871c47492..5d9fd6a52953d6d7e73a044d38a5f27b469e533f 100644 (file)
@@ -57,11 +57,5 @@ if(WITH_EVENTTRACE)
 endif()
 
 if(WITH_LIBURING)
-  if(WITH_SYSTEM_LIBURING)
-    find_package(uring REQUIRED)
-  else()
-    include(Builduring)
-    build_uring()
-  endif()
   target_link_libraries(blk PRIVATE uring::uring)
 endif()