]> git.apps.os.sepia.ceph.com Git - ceph-ci.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>
Tue, 17 Oct 2023 17:00:14 +0000 (13:00 -0400)
For use by multiple projects, rocksdb in particular.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
CMakeLists.txt
src/blk/CMakeLists.txt

index 34d035b4df86ba4d74e120e415bc362da315d19b..28c9209c55793b288bbacf980fbe2c36b874bac0 100644 (file)
@@ -256,6 +256,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()