]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: rgw_d3n_datacache.cc add check for musl 47831/head
authorDuncan Bellamy <dunk@denkimushi.com>
Sat, 27 Aug 2022 09:28:35 +0000 (10:28 +0100)
committerDuncan Bellamy <dunk@denkimushi.com>
Sat, 27 Aug 2022 09:28:35 +0000 (10:28 +0100)
aio_init is glibc specific

Fixes: https://tracker.ceph.com/issues/54414
Signed-off-by: Duncan Bellamy <dunk@denkimushi.com>
src/rgw/rgw_d3n_datacache.cc

index 472d2d57d590bc2b890e3cab684faf63e7435b46..ed375e2ac943ca24a343f915d4bf54476bcb3a3f 100644 (file)
@@ -9,6 +9,9 @@
 #include "rgw_auth_s3.h"
 #include "rgw_op.h"
 #include "rgw_crypt_sanitize.h"
+#if defined(__linux__)
+#include <features.h>
+#endif
 
 #if __has_include(<filesystem>)
 #include <filesystem>
@@ -97,7 +100,7 @@ void D3nDataCache::init(CephContext *_cct) {
   if (conf_eviction_policy == "random")
     eviction_policy = _eviction_policy::RANDOM;
 
-#if defined(HAVE_LIBAIO)
+#if defined(HAVE_LIBAIO) && defined(__GLIBC__)
   // libaio setup
   struct aioinit ainit{0};
   ainit.aio_threads = cct->_conf.get_val<int64_t>("rgw_d3n_libaio_aio_threads");