X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=ceph%2FCMakeLists.txt;h=2e2df1f6e75f1fabe235d01a4116123eeff0500e;hb=28e407b858acd3bddc89f68583571f771bb42e46;hp=bc7dd87eeb8b3572708e2299a5be6c588ca46adb;hpb=35e4c4457ede68661c55bb19d5cb7acb7f8b39eb;p=ceph.git diff --git a/ceph/CMakeLists.txt b/ceph/CMakeLists.txt index bc7dd87ee..2e2df1f6e 100644 --- a/ceph/CMakeLists.txt +++ b/ceph/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 2.8.11) project(ceph) -set(VERSION 12.1.4) +set(VERSION 12.2.7) if(POLICY CMP0046) # Tweak policies (this one disables "missing" dependency warning) @@ -112,6 +112,7 @@ CHECK_FUNCTION_EXISTS(pthread_spin_init HAVE_PTHREAD_SPINLOCK) CHECK_FUNCTION_EXISTS(pthread_set_name_np HAVE_PTHREAD_SET_NAME_NP) CHECK_FUNCTION_EXISTS(pthread_setname_np HAVE_PTHREAD_SETNAME_NP) CHECK_FUNCTION_EXISTS(pthread_getname_np HAVE_PTHREAD_GETNAME_NP) +CHECK_FUNCTION_EXISTS(pthread_rwlockattr_setkind_np HAVE_PTHREAD_RWLOCKATTR_SETKIND_NP) CHECK_FUNCTION_EXISTS(eventfd HAVE_EVENTFD) CHECK_FUNCTION_EXISTS(getprogname HAVE_GETPROGNAME) @@ -274,7 +275,7 @@ find_package(snappy REQUIRED) option(WITH_LZ4 "LZ4 compression support" OFF) if(WITH_LZ4) - find_package(LZ4 REQUIRED) + find_package(LZ4 1.7 REQUIRED) set(HAVE_LZ4 ${LZ4_FOUND}) endif(WITH_LZ4) @@ -362,6 +363,11 @@ if(WITH_BLKIN) include_directories(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) @@ -371,6 +377,10 @@ 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() endif(WITH_RADOSGW) @@ -379,7 +389,24 @@ if (WITH_RADOSGW) message(STATUS "Looking for openssl anyways, because radosgw selected") find_package(OpenSSL) endif() +# https://curl.haxx.se/docs/install.html mentions the +# configure flags for various ssl backends + execute_process( + COMMAND + "sh" "-c" + "curl-config --configure | grep with-ssl" + RESULT_VARIABLE NO_CURL_SSL_LINK + ERROR_VARIABLE CURL_CONFIG_ERRORS + ) + if (CURL_CONFIG_ERRORS) + message(WARNING "unable to run curl-config; rgw cannot make ssl requests to external systems reliably") + endif() + find_package(OpenSSL) if (OPENSSL_FOUND) + if (NOT NO_CURL_SSL_LINK) + message(STATUS "libcurl is linked with openssl: explicitly setting locks") + set(WITH_CURL_OPENSSL ON) + endif() # CURL_SSL_LINK execute_process( COMMAND "sh" "-c" @@ -412,7 +439,7 @@ if (WITH_RADOSGW) message(STATUS "crypto soname: ${LIBCRYPTO_SONAME}") else() message(WARNING "ssl not found: rgw civetweb may fail to dlopen libssl libcrypto") - endif() + endif() # OPENSSL_FOUND endif (WITH_RADOSGW) #option for CephFS @@ -542,9 +569,8 @@ set(BOOST_HEADER_COMPONENTS container) if(WITH_MGR) list(APPEND BOOST_COMPONENTS python) endif() - -if(WITH_RADOSGW_BEAST_FRONTEND) - list(APPEND BOOST_COMPONENTS coroutine context) +if(WITH_BOOST_CONTEXT) + list(APPEND BOOST_COMPONENTS context coroutine) endif() set(Boost_USE_MULTITHREADED ON) @@ -555,13 +581,13 @@ if(WITH_SYSTEM_BOOST) else() set(Boost_USE_STATIC_LIBS ON) endif() - find_package(Boost 1.61 COMPONENTS ${BOOST_COMPONENTS} REQUIRED) + find_package(Boost 1.66 COMPONENTS ${BOOST_COMPONENTS} REQUIRED) else() set(BOOST_J 1 CACHE STRING "max jobs for Boost build") # override w/-DBOOST_J= set(Boost_USE_STATIC_LIBS ON) include(BuildBoost) - build_boost(1.63 + build_boost(1.66 COMPONENTS ${BOOST_COMPONENTS} ${BOOST_HEADER_COMPONENTS}) include_directories(BEFORE SYSTEM ${Boost_INCLUDE_DIRS}) endif() @@ -602,6 +628,10 @@ if(WITH_SYSTEMD) add_subdirectory(systemd) endif() +if(LINUX) + add_subdirectory(etc/sysctl) +endif() + include(CTags) option(CTAG_EXCLUDES "Exclude files/directories when running ctag.") add_tags(ctags