]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
{rgw, cmake}: Remove WITH_BOOST_CONTEXT
authorAdam C. Emerson <aemerson@redhat.com>
Thu, 22 Oct 2020 18:55:17 +0000 (14:55 -0400)
committerAdam C. Emerson <aemerson@redhat.com>
Fri, 23 Oct 2020 15:21:53 +0000 (11:21 -0400)
As Boost.Context now supports s390, there is no longer any need for
the conditional compilation.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
21 files changed:
CMakeLists.txt
src/CMakeLists.txt
src/common/async/yield_context.h
src/include/config-h.in.cmake
src/rgw/CMakeLists.txt
src/rgw/rgw_aio.cc
src/rgw/rgw_aio_throttle.cc
src/rgw/rgw_aio_throttle.h
src/rgw/rgw_http_client.cc
src/rgw/rgw_pubsub_push.cc
src/rgw/rgw_reshard.cc
src/rgw/rgw_tools.cc
src/test/CMakeLists.txt
src/test/cls_fifo/CMakeLists.txt
src/test/librados/CMakeLists.txt
src/test/librados/asio.cc
src/test/rgw/CMakeLists.txt
src/test/rgw/test_rgw_dmclock_scheduler.cc
src/test/rgw/test_rgw_reshard_wait.cc
src/test/rgw/test_rgw_throttle.cc
src/tools/CMakeLists.txt

index 660aa27eb56e401a593b1ac72c33b8389d8f473e..c8065e54f2279a34ac9b45501380e79dc5bb0e08 100644 (file)
@@ -357,11 +357,6 @@ if(WITH_BLKIN)
   include_directories(SYSTEM src/blkin/blkin-lib)
 endif(WITH_BLKIN)
 
-option(WITH_BOOST_CONTEXT "Enable boost::asio stackful coroutines" ON)
-if(WITH_BOOST_CONTEXT)
-  set(HAVE_BOOST_CONTEXT ON)
-endif()
-
 #option for RGW
 option(WITH_RADOSGW "Rados Gateway is enabled" ON)
 option(WITH_RADOSGW_FCGI_FRONTEND "Rados Gateway's FCGI frontend is enabled" OFF)
@@ -375,10 +370,6 @@ if(WITH_RADOSGW)
   if(WITH_RADOSGW_FCGI_FRONTEND)
     find_package(fcgi REQUIRED)
   endif()
-  if(WITH_RADOSGW_BEAST_FRONTEND AND NOT WITH_BOOST_CONTEXT)
-    message(WARNING "disabling WITH_RADOSGW_BEAST_FRONTEND, which depends on WITH_BOOST_CONTEXT")
-    set(WITH_RADOSGW_BEAST_FRONTEND OFF)
-  endif()
   find_package(OATH REQUIRED)
 
 # https://curl.haxx.se/docs/install.html mentions the
@@ -568,16 +559,13 @@ option(WITH_SYSTEM_BOOST "require and build with system Boost" OFF)
 # Boost::thread depends on Boost::atomic, so list it explicitly.
 set(BOOST_COMPONENTS
   atomic chrono thread system regex random program_options date_time
-  iostreams)
+  iostreams context coroutine)
 set(BOOST_HEADER_COMPONENTS container)
 
 if(WITH_MGR)
   list(APPEND BOOST_COMPONENTS
     python${MGR_PYTHON_VERSION_MAJOR}${MGR_PYTHON_VERSION_MINOR})
 endif()
-if(WITH_BOOST_CONTEXT)
-  list(APPEND BOOST_COMPONENTS context coroutine)
-endif()
 if(WITH_SEASTAR)
   list(APPEND BOOST_COMPONENTS filesystem timer)
 endif()
index 75cba9393ef3c0b3237b5c326f3b528dc29518c9..5526e469c4a3ec3ccc6a2e297e3bdd11d598a5d8 100644 (file)
@@ -778,11 +778,9 @@ if(WITH_RBD)
   add_subdirectory(rbd_replay)
 endif(WITH_RBD)
 
-if(WITH_BOOST_CONTEXT)
-  set(SPAWN_BUILD_TESTS OFF CACHE INTERNAL "disable building of spawn unit tests")
-  set(SPAWN_INSTALL OFF CACHE INTERNAL "disable installation of spawn headers")
-  add_subdirectory(spawn)
-endif()
+set(SPAWN_BUILD_TESTS OFF CACHE INTERNAL "disable building of spawn unit tests")
+set(SPAWN_INSTALL OFF CACHE INTERNAL "disable installation of spawn headers")
+add_subdirectory(spawn)
 
 # RadosGW
 if(WITH_KVS)
index fdfb3f5b8fe1a4586981c239af5a4df0f15975b0..baa028fa1b4afa7d2d1774af93d899efd2a90c6c 100644 (file)
 
 #include "acconfig.h"
 
-#ifndef HAVE_BOOST_CONTEXT
-
-// hide the dependency on boost::context
-namespace spawn {
-struct yield_context;
-}
-
-#else // HAVE_BOOST_CONTEXT
 #include <spawn/spawn.hpp>
 
-#endif // HAVE_BOOST_CONTEXT
-
-
 /// optional-like wrapper for a spawn::yield_context and its associated
 /// boost::asio::io_context. operations that take an optional_yield argument
 /// will, when passed a non-empty yield context, suspend this coroutine instead
index c6206dd992869d829132a42248f5646a98cd24d2..b5a81eb772d08f414ea6ff357088d5f960d261be 100644 (file)
 /* Defined if getentropy() is available */
 #cmakedefine HAVE_GETENTROPY
 
-/* Defined if boost::context is available */
-#cmakedefine HAVE_BOOST_CONTEXT
-
 /* Defined if libradosstriper is enabled: */
 #cmakedefine WITH_LIBRADOSSTRIPER
 
index 7d4523d55a3dbb91a2024872fdf9cc00b8e4c947..3a1838a21cd258e77e7b6d7c914c8e66dff4d162 100644 (file)
@@ -177,10 +177,8 @@ target_include_directories(rgw_common PRIVATE "${CMAKE_SOURCE_DIR}/src/lua/src")
 target_include_directories(rgw_common PRIVATE "${CMAKE_BINARY_DIR}/src/lua")
 
 
-if(WITH_BOOST_CONTEXT)
-  target_include_directories(rgw_common PRIVATE
-    $<TARGET_PROPERTY:spawn,INTERFACE_INCLUDE_DIRECTORIES>)
-endif()
+target_include_directories(rgw_common PRIVATE
+  $<TARGET_PROPERTY:spawn,INTERFACE_INCLUDE_DIRECTORIES>)
 
 if(WITH_LTTNG)
   # rgw/rgw_op.cc includes "tracing/rgw_op.h"
@@ -259,10 +257,7 @@ if(WITH_CURL_OPENSSL)
 endif()
 
 target_link_libraries(rgw_a PRIVATE liblua)
-
-if(WITH_BOOST_CONTEXT)
-  target_link_libraries(rgw_a PUBLIC spawn)
-endif()
+target_link_libraries(rgw_a PUBLIC spawn)
 
 set(rgw_libs rgw_a)
 if(WITH_RADOSGW_AMQP_ENDPOINT)
index 48c83be98ac8ac210754aea01530a8e6c2552fda..56ef415e35036cef6c645e141bd56f8abe646859 100644 (file)
@@ -61,7 +61,6 @@ Aio::OpFunc aio_abstract(Op&& op) {
     };
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 struct Handler {
   Aio* throttle = nullptr;
   AioResult& r;
@@ -93,19 +92,16 @@ Aio::OpFunc aio_abstract(Op&& op, boost::asio::io_context& context,
                               bind_executor(ex, Handler{aio, r}));
     };
 }
-#endif // HAVE_BOOST_CONTEXT
 
 template <typename Op>
 Aio::OpFunc aio_abstract(Op&& op, optional_yield y) {
   static_assert(std::is_base_of_v<librados::ObjectOperation, std::decay_t<Op>>);
   static_assert(!std::is_lvalue_reference_v<Op>);
   static_assert(!std::is_const_v<Op>);
-#ifdef HAVE_BOOST_CONTEXT
   if (y) {
     return aio_abstract(std::forward<Op>(op), y.get_io_context(),
                         y.get_yield_context());
   }
-#endif
   return aio_abstract(std::forward<Op>(op));
 }
 
index 57d7e7fb9f1679a8247dcbd8266f6d7a7ef72db4..8ada6db34a91bcf3d065bd668b48187b6d1d78e3 100644 (file)
@@ -109,8 +109,6 @@ AioResultList BlockingAioThrottle::drain()
   return std::move(completed);
 }
 
-#ifdef HAVE_BOOST_CONTEXT
-
 template <typename CompletionToken>
 auto YieldingAioThrottle::async_wait(CompletionToken&& token)
 {
@@ -201,6 +199,4 @@ AioResultList YieldingAioThrottle::drain()
   }
   return std::move(completed);
 }
-#endif // HAVE_BOOST_CONTEXT
-
 } // namespace rgw
index 764469d7ed38b6d3d77ce3e0430ee83f3cb8a523..04e93aaa09e890265b402c0dde30e626e8a5c0d7 100644 (file)
@@ -78,7 +78,6 @@ class BlockingAioThrottle final : public Aio, private Throttle {
   AioResultList drain() override final;
 };
 
-#ifdef HAVE_BOOST_CONTEXT
 // a throttle that yields the coroutine instead of blocking. all public
 // functions must be called within the coroutine strand
 class YieldingAioThrottle final : public Aio, private Throttle {
@@ -112,12 +111,10 @@ class YieldingAioThrottle final : public Aio, private Throttle {
 
   AioResultList drain() override final;
 };
-#endif // HAVE_BOOST_CONTEXT
 
 // return a smart pointer to Aio
 inline auto make_throttle(uint64_t window_size, optional_yield y)
 {
-#ifdef HAVE_BOOST_CONTEXT
   std::unique_ptr<Aio> aio;
   if (y) {
     aio = std::make_unique<YieldingAioThrottle>(window_size,
@@ -127,9 +124,6 @@ inline auto make_throttle(uint64_t window_size, optional_yield y)
     aio = std::make_unique<BlockingAioThrottle>(window_size);
   }
   return aio;
-#else
-  return std::make_optional<BlockingAioThrottle>(window_size);
-#endif
 }
 
 } // namespace rgw
index 902c314515e176c9aafb6a5010dac8da6950feb1..15be26f5229beea8d7821065f62b15ffed177988 100644 (file)
@@ -74,7 +74,6 @@ struct rgw_http_req_data : public RefCountedObject {
     if (done) {
       return ret;
     }
-#ifdef HAVE_BOOST_CONTEXT
     if (y) {
       auto& context = y.get_io_context();
       auto& yield = y.get_yield_context();
@@ -86,7 +85,6 @@ struct rgw_http_req_data : public RefCountedObject {
     if (is_asio_thread) {
       dout(20) << "WARNING: blocking http request" << dendl;
     }
-#endif
     std::unique_lock l{lock};
     cond.wait(l, [this]{return done==true;});
     return ret;
index 0f927e4f46fc3f4dfd1b865960dcb914b2128d42..5e2e26bcbdac08366f8e7a4316ce8a73c663189a 100644 (file)
@@ -350,15 +350,13 @@ public:
       if (done) {
         return ret;
       }
-#ifdef HAVE_BOOST_CONTEXT
       if (y) {
-        auto& io_ctx = y.get_io_context();
+       auto& io_ctx = y.get_io_context();
         auto& yield_ctx = y.get_yield_context();
         boost::system::error_code ec;
         async_wait(io_ctx, yield_ctx[ec]);
         return -ec.value();
       }
-#endif
       std::unique_lock l(lock);
       cond.wait(l, [this]{return (done==true);});
       return ret;
@@ -622,7 +620,6 @@ public:
       if (done) {
         return ret;
       }
-#ifdef HAVE_BOOST_CONTEXT
       if (y) {
         auto& io_ctx = y.get_io_context();
         auto& yield_ctx = y.get_yield_context();
@@ -630,7 +627,6 @@ public:
         async_wait(io_ctx, yield_ctx[ec]);
         return -ec.value();
       }
-#endif
       std::unique_lock l(lock);
       cond.wait(l, [this]{return (done==true);});
       return ret;
index 27ed143509671411d745ed85b062d415bc5b1c08..68352f3e56ad446aa13374ff8c829d35c50e1c85 100644 (file)
@@ -938,7 +938,6 @@ int RGWReshardWait::wait(optional_yield y)
     return -ECANCELED;
   }
 
-#ifdef HAVE_BOOST_CONTEXT
   if (y) {
     auto& context = y.get_io_context();
     auto& yield = y.get_yield_context();
@@ -956,7 +955,6 @@ int RGWReshardWait::wait(optional_yield y)
     waiters.erase(waiters.iterator_to(waiter));
     return -ec.value();
   }
-#endif
 
   cond.wait_for(lock, duration);
 
index 10b2e69893d22e8c1938cfbc78ef9dbc60fdd52f..5b2d2579147448f5d18f9d3682e11aa8b4ae9a77 100644 (file)
@@ -250,7 +250,6 @@ int rgw_rados_operate(librados::IoCtx& ioctx, const std::string& oid,
                       librados::ObjectReadOperation *op, bufferlist* pbl,
                       optional_yield y, int flags)
 {
-#ifdef HAVE_BOOST_CONTEXT
   // given a yield_context, call async_operate() to yield the coroutine instead
   // of blocking
   if (y) {
@@ -268,7 +267,6 @@ int rgw_rados_operate(librados::IoCtx& ioctx, const std::string& oid,
   if (is_asio_thread) {
     dout(20) << "WARNING: blocking librados call" << dendl;
   }
-#endif
   return ioctx.operate(oid, op, nullptr, flags);
 }
 
@@ -276,7 +274,6 @@ int rgw_rados_operate(librados::IoCtx& ioctx, const std::string& oid,
                       librados::ObjectWriteOperation *op, optional_yield y,
                      int flags)
 {
-#ifdef HAVE_BOOST_CONTEXT
   if (y) {
     auto& context = y.get_io_context();
     auto& yield = y.get_yield_context();
@@ -287,7 +284,6 @@ int rgw_rados_operate(librados::IoCtx& ioctx, const std::string& oid,
   if (is_asio_thread) {
     dout(20) << "WARNING: blocking librados call" << dendl;
   }
-#endif
   return ioctx.operate(oid, op, flags);
 }
 
@@ -295,7 +291,6 @@ int rgw_rados_notify(librados::IoCtx& ioctx, const std::string& oid,
                      bufferlist& bl, uint64_t timeout_ms, bufferlist* pbl,
                      optional_yield y)
 {
-#ifdef HAVE_BOOST_CONTEXT
   if (y) {
     auto& context = y.get_io_context();
     auto& yield = y.get_yield_context();
@@ -310,7 +305,6 @@ int rgw_rados_notify(librados::IoCtx& ioctx, const std::string& oid,
   if (is_asio_thread) {
     dout(20) << "WARNING: blocking librados call" << dendl;
   }
-#endif
   return ioctx.notify2(oid, bl, timeout_ms, pbl);
 }
 
index e1efef2bbebf3f689aec8e73da663c58638b5939..6ab0f0c8b414cf632c202af1738b1fcdcdb6c34a 100644 (file)
@@ -8,9 +8,7 @@ target_include_directories(unit-main PRIVATE
   $<TARGET_PROPERTY:GTest::GTest,INTERFACE_INCLUDE_DIRECTORIES>)
 
 add_subdirectory(cls_hello)
-if(WITH_BOOST_CONTEXT)
 add_subdirectory(cls_fifo)
-endif()
 add_subdirectory(cls_lock)
 add_subdirectory(cls_cas)
 add_subdirectory(cls_log)
@@ -294,10 +292,7 @@ target_link_libraries(ceph_test_librgw_file_nfsns
   ${UNITTEST_LIBS}
   ${EXTRALIBS}
   )
-if(WITH_BOOST_CONTEXT)
   target_link_libraries(ceph_test_librgw_file_nfsns spawn)
-endif()
-
 
 # ceph_test_librgw_file_aw (nfs write transaction [atomic write] tests)
 add_executable(ceph_test_librgw_file_aw
@@ -323,9 +318,7 @@ target_link_libraries(ceph_test_librgw_file_marker
   ${UNITTEST_LIBS}
   ${EXTRALIBS}
   )
-if(WITH_BOOST_CONTEXT)
   target_link_libraries(ceph_test_librgw_file_marker spawn)
-endif()
 
 # ceph_test_rgw_token
 add_executable(ceph_test_rgw_token
index 492e6e1f9a1c4f2c7c99883c5cbc36e8d27a1fff..c71ed790f94dbef2d641bc1f1a56feb6bc337f1f 100644 (file)
@@ -1,4 +1,3 @@
-if(WITH_BOOST_CONTEXT)
 add_executable(ceph_test_cls_fifo
   test_cls_fifo.cc
   )
@@ -37,4 +36,3 @@ target_link_libraries(ceph_bench_cls_fifo
 install(TARGETS
   ceph_test_cls_fifo
   DESTINATION ${CMAKE_INSTALL_BINDIR})
-endif()
index 2fd73de4b0446a81bd612c36e8c8e0230ddd61e5..77520e01d17d8463491bec2877f3a3bba2c88e5d 100644 (file)
@@ -60,10 +60,7 @@ target_link_libraries(ceph_test_rados_api_aio_pp
 
 add_executable(ceph_test_rados_api_asio asio.cc)
 target_link_libraries(ceph_test_rados_api_asio global
-  librados ${UNITTEST_LIBS})
-if(WITH_BOOST_CONTEXT)
-  target_link_libraries(ceph_test_rados_api_asio Boost::coroutine Boost::context)
-endif()
+  librados ${UNITTEST_LIBS} Boost::coroutine Boost::context)
 
 add_executable(ceph_test_rados_api_list
   list.cc
@@ -132,10 +129,8 @@ add_executable(ceph_test_rados_api_tier_pp
   tier_cxx.cc
   $<TARGET_OBJECTS:unit-main>)
 target_link_libraries(ceph_test_rados_api_tier_pp
-  librados global ${UNITTEST_LIBS} Boost::system radostest-cxx cls_cas_internal)
-if(WITH_BOOST_CONTEXT)
-  target_link_libraries(ceph_test_rados_api_tier_pp spawn)
-endif()
+  librados global ${UNITTEST_LIBS} Boost::system radostest-cxx cls_cas_internal
+  spawn)
 
 add_executable(ceph_test_rados_api_snapshots
   snapshots.cc)
index 8fa4bab197790ac7444780e05b1bb524dd3989c4..9dd6b00fe0f88fe632420341d8a4fdc8d3c47bf8 100644 (file)
 #include "common/errno.h"
 #include "global/global_init.h"
 
-#ifdef HAVE_BOOST_CONTEXT
 #define BOOST_COROUTINES_NO_DEPRECATION_WARNING
 #include <boost/range/begin.hpp>
 #include <boost/range/end.hpp>
 #include <boost/asio/spawn.hpp>
-#endif
 #include <boost/asio/use_future.hpp>
 
 #define dout_subsys ceph_subsys_rados
@@ -109,7 +107,6 @@ TEST_F(AsioRados, AsyncReadFuture)
   EXPECT_THROW(f2.get(), boost::system::system_error);
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST_F(AsioRados, AsyncReadYield)
 {
   boost::asio::io_service service;
@@ -131,7 +128,6 @@ TEST_F(AsioRados, AsyncReadYield)
 
   service.run();
 }
-#endif
 
 TEST_F(AsioRados, AsyncWriteCallback)
 {
@@ -173,7 +169,6 @@ TEST_F(AsioRados, AsyncWriteFuture)
   EXPECT_THROW(f2.get(), boost::system::system_error);
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST_F(AsioRados, AsyncWriteYield)
 {
   boost::asio::io_service service;
@@ -200,7 +195,6 @@ TEST_F(AsioRados, AsyncWriteYield)
 
   service.run();
 }
-#endif
 
 TEST_F(AsioRados, AsyncReadOperationCallback)
 {
@@ -251,7 +245,6 @@ TEST_F(AsioRados, AsyncReadOperationFuture)
   EXPECT_THROW(f2.get(), boost::system::system_error);
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST_F(AsioRados, AsyncReadOperationYield)
 {
   boost::asio::io_service service;
@@ -279,7 +272,6 @@ TEST_F(AsioRados, AsyncReadOperationYield)
 
   service.run();
 }
-#endif
 
 TEST_F(AsioRados, AsyncWriteOperationCallback)
 {
@@ -334,7 +326,6 @@ TEST_F(AsioRados, AsyncWriteOperationFuture)
   EXPECT_THROW(f2.get(), boost::system::system_error);
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST_F(AsioRados, AsyncWriteOperationYield)
 {
   boost::asio::io_service service;
@@ -362,7 +353,6 @@ TEST_F(AsioRados, AsyncWriteOperationYield)
 
   service.run();
 }
-#endif
 
 int main(int argc, char **argv)
 {
index 1251e3c281114101139e26e3c90c98d786e9e856..78598f737dbd4628dde856cec635a0a0d628f65e 100644 (file)
@@ -164,10 +164,8 @@ add_executable(unittest_rgw_dmclock_scheduler test_rgw_dmclock_scheduler.cc $<TA
 add_ceph_unittest(unittest_rgw_dmclock_scheduler)
 
 target_link_libraries(unittest_rgw_dmclock_scheduler rgw_schedulers global ${UNITTEST_LIBS})
-if(WITH_BOOST_CONTEXT)
-  target_compile_definitions(unittest_rgw_dmclock_scheduler PRIVATE BOOST_COROUTINES_NO_DEPRECATION_WARNING)
-  target_link_libraries(unittest_rgw_dmclock_scheduler Boost::coroutine Boost::context)
-endif()
+target_compile_definitions(unittest_rgw_dmclock_scheduler PRIVATE BOOST_COROUTINES_NO_DEPRECATION_WARNING)
+target_link_libraries(unittest_rgw_dmclock_scheduler Boost::coroutine Boost::context)
 
 if(WITH_RADOSGW_AMQP_ENDPOINT)
   add_executable(unittest_rgw_amqp test_rgw_amqp.cc)
index b7e9b0eabf7cacf0bd3f936cf034a2a65a0a344d..d13c4fca69e58e808085fba232d62a7309402d39 100644 (file)
@@ -18,9 +18,7 @@
 #include "rgw/rgw_dmclock_async_scheduler.h"
 
 #include <optional>
-#ifdef HAVE_BOOST_CONTEXT
 #include <boost/asio/spawn.hpp>
-#endif
 #include <gtest/gtest.h>
 #include "acconfig.h"
 #include "global/global_context.h"
@@ -78,7 +76,6 @@ TEST(Queue, SyncRequest)
   EXPECT_EQ(0u, counters(client_id::auth)->get(queue_counters::l_cancel));
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST(Queue, RateLimit)
 {
   boost::asio::io_context context;
@@ -428,6 +425,4 @@ TEST(Queue, SpawnAsyncRequest)
   EXPECT_TRUE(context.stopped());
 }
 
-#endif
-
 } // namespace rgw::dmclock
index a1f55b5a71686d202d87905e4bd1f21fc1cef1cb..fa947c4f3c2c45afd377624c103d7250a6b051d9 100644 (file)
@@ -13,9 +13,7 @@
  */
 
 #include "rgw/rgw_reshard.h"
-#ifdef HAVE_BOOST_CONTEXT
 #include <spawn/spawn.hpp>
-#endif
 
 #include <gtest/gtest.h>
 
@@ -60,7 +58,6 @@ TEST(ReshardWait, stop_block)
   short_waiter.stop();
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST(ReshardWait, wait_yield)
 {
   constexpr ceph::timespan wait_duration = 50ms;
@@ -165,4 +162,3 @@ TEST(ReshardWait, stop_multiple)
   EXPECT_GT(long_duration, elapsed); // waited less than 10s
   short_waiter.stop();
 }
-#endif // HAVE_BOOST_CONTEXT
index fff680012f4df02282a99037cd5760d6e6257b58..5a520bf2a5da7b8f1b74f0cb6d24f95d88f1b740 100644 (file)
@@ -18,9 +18,7 @@
 #include <thread>
 #include "include/scope_guard.h"
 
-#ifdef HAVE_BOOST_CONTEXT
 #include <spawn/spawn.hpp>
-#endif
 #include <gtest/gtest.h>
 
 struct RadosEnv : public ::testing::Environment {
@@ -166,7 +164,6 @@ TEST_F(Aio_Throttle, ThrottleOverMax)
   EXPECT_EQ(window, max_outstanding);
 }
 
-#ifdef HAVE_BOOST_CONTEXT
 TEST_F(Aio_Throttle, YieldCostOverWindow)
 {
   auto obj = make_obj(__PRETTY_FUNCTION__);
@@ -216,6 +213,5 @@ TEST_F(Aio_Throttle, YieldingThrottleOverMax)
   EXPECT_EQ(0u, outstanding);
   EXPECT_EQ(window, max_outstanding);
 }
-#endif // HAVE_BOOST_CONTEXT
 
 } // namespace rgw
index 3c2168b92bf9603efb093be4e3ba7e495f2cf0c0..5be9fd3413b67b08967a7f491ecf06ede96552d1 100644 (file)
@@ -16,16 +16,16 @@ else()
 endif()
 install(TARGETS rados DESTINATION bin)
 
-if(WITH_BOOST_CONTEXT AND NOT WIN32)
+if(NOT WIN32)
 set(neorados_srcs
   neorados.cc)
 add_executable(neorados ${neorados_srcs})
 target_include_directories(neorados PRIVATE
   $<TARGET_PROPERTY:spawn,INTERFACE_INCLUDE_DIRECTORIES>)
+endif()
 
 target_link_libraries(neorados libneorados spawn ${CMAKE_DL_LIBS})
 #install(TARGETS neorados DESTINATION bin)
-endif()
 
 if(WITH_TESTS)
 add_executable(ceph_scratchtool scratchtool.c)