]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
cmake: add WITH_SEASTAR option
authorCasey Bodley <cbodley@redhat.com>
Sun, 8 Oct 2017 18:46:26 +0000 (14:46 -0400)
committerKefu Chai <kchai@redhat.com>
Fri, 8 Jun 2018 12:58:15 +0000 (20:58 +0800)
Signed-off-by: Casey Bodley <cbodley@redhat.com>
CMakeLists.txt
src/CMakeLists.txt
src/include/config-h.in.cmake

index d557536c20531c47d6838173851e3cb7f1539c9b..77b7438515a8f642eeca1aa54b225c48c9d331ed 100644 (file)
@@ -581,6 +581,9 @@ if (WITH_SYSTEM_ROCKSDB)
   find_package(rocksdb 5.8 REQUIRED)
 endif()
 
+option(WITH_SEASTAR "Build seastar components")
+set(HAVE_SEASTAR ${WITH_SEASTAR})
+
 # Boost
 option(WITH_SYSTEM_BOOST "require and build with system Boost" OFF)
 
@@ -595,6 +598,7 @@ endif()
 if(WITH_BOOST_CONTEXT)
   list(APPEND BOOST_COMPONENTS context coroutine)
 endif()
+list(APPEND BOOST_COMPONENTS test timer)
 
 set(Boost_USE_MULTITHREADED ON)
 # require minimally the bundled version
index e26fc79ce6f25dcf75105ee8e79b0cc9117b82df..4fa6b1eaf98e695c9a5b324093603e408a0fe3c2 100644 (file)
@@ -39,7 +39,7 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL GNU)
   set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -rdynamic")
   set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wstrict-null-sentinel -Woverloaded-virtual")
   set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-new-ttp-matching")
-  if(NOT WITH_OSD_INSTRUMENT_FUNCTIONS)
+  if(NOT WITH_OSD_INSTRUMENT_FUNCTIONS AND NOT HAVE_SEASTAR)
     set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pie")
   endif()
 elseif(CMAKE_CXX_COMPILER_ID STREQUAL Clang)
@@ -387,6 +387,10 @@ include_directories("${CMAKE_SOURCE_DIR}/src/dmclock/support/src")
 # needed for source files that friend unit tests (e.g., using FRIEND_TEST)
 include_directories(SYSTEM "${CMAKE_SOURCE_DIR}/src/googletest/googletest/include")
 
+if(WITH_SEASTAR)
+  add_subdirectory(seastar)
+endif()
+
 set(xio_common_srcs)
 if(HAVE_XIO)
   list(APPEND xio_common_srcs
index e6f66e73c2dbfb03f45ebcdd829f63359a5847c9..42800a5ccdd1a443b602057e3a2fef665c039bc9 100644 (file)
 /* Defined if Intel QAT compress/decompress is supported */
 #cmakedefine HAVE_QATZIP
 
+/* Define if seastar is available. */
+#cmakedefine HAVE_SEASTAR
+
 #endif /* CONFIG_H */