From: Adam C. Emerson Date: Mon, 15 May 2023 22:31:38 +0000 (-0400) Subject: build: Bump boost to 1.82 X-Git-Tag: v19.0.0~903^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=244c5ebbd4d5683da7f57612cc02e946aae7fd73;p=ceph.git build: Bump boost to 1.82 Needed to fix coroutine detection under Clang Signed-off-by: Adam C. Emerson --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 8ac7b5c953b44..2852a7488acb4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -661,7 +661,7 @@ if(WITH_SYSTEM_BOOST) if(BOOST_ROOT AND CMAKE_LIBRARY_ARCHITECTURE) set(BOOST_LIBRARYDIR "${BOOST_ROOT}/lib/${CMAKE_LIBRARY_ARCHITECTURE}") endif() - find_package(Boost 1.79 COMPONENTS ${BOOST_COMPONENTS} REQUIRED) + find_package(Boost 1.82 COMPONENTS ${BOOST_COMPONENTS} REQUIRED) if(NOT ENABLE_SHARED) set_property(TARGET Boost::iostreams APPEND PROPERTY INTERFACE_LINK_LIBRARIES ZLIB::ZLIB) @@ -675,11 +675,16 @@ else() set(BOOST_J ${DEFAULT_BOOST_J} CACHE STRING "max jobs for Boost build") # override w/-DBOOST_J= set(Boost_USE_STATIC_LIBS ON) include(BuildBoost) - build_boost(1.79 + build_boost(1.82 COMPONENTS ${BOOST_COMPONENTS} ${BOOST_HEADER_COMPONENTS}) endif() include_directories(BEFORE SYSTEM ${Boost_INCLUDE_DIRS}) +if(Boost_VERSION VERSION_EQUAL 1.81 OR Boost_VERSION VERSION_EQUAL 1.82) + # This is a workaround for https://github.com/boostorg/phoenix/issues/111 + add_compile_options($<$:-DBOOST_PHOENIX_STL_TUPLE_H_>) +endif() + # dashboard angular2 frontend option(WITH_MGR_DASHBOARD_FRONTEND "Build the mgr/dashboard frontend using `npm`" ON) option(WITH_SYSTEM_NPM "Assume that dashboard build tools already installed through packages" OFF) diff --git a/cmake/modules/BuildBoost.cmake b/cmake/modules/BuildBoost.cmake index 8cccecd144bc4..a225787959081 100644 --- a/cmake/modules/BuildBoost.cmake +++ b/cmake/modules/BuildBoost.cmake @@ -149,14 +149,14 @@ function(do_build_boost root_dir version) check_boost_version("${PROJECT_SOURCE_DIR}/src/boost" ${version}) set(source_dir SOURCE_DIR "${PROJECT_SOURCE_DIR}/src/boost") - elseif(version VERSION_GREATER 1.79) + elseif(version VERSION_GREATER 1.82) message(FATAL_ERROR "Unknown BOOST_REQUESTED_VERSION: ${version}") else() message(STATUS "boost will be downloaded...") # NOTE: If you change this version number make sure the package is available # at the three URLs below (may involve uploading to download.ceph.com) - set(boost_version 1.79.0) - set(boost_sha256 475d589d51a7f8b3ba2ba4eda022b170e562ca3b760ee922c146b6c65856ef39) + set(boost_version 1.82.0) + set(boost_sha256 a6e1ab9b0860e6a2881dd7b21fe9f737a095e5f33a3a874afc6a345228597ee6) string(REPLACE "." "_" boost_version_underscore ${boost_version} ) string(JOIN " " boost_url https://boostorg.jfrog.io/artifactory/main/release/${boost_version}/source/boost_${boost_version_underscore}.tar.bz2 diff --git a/cmake/modules/FindBoost.cmake b/cmake/modules/FindBoost.cmake index cf0326a1edae6..d47c4862dd08b 100644 --- a/cmake/modules/FindBoost.cmake +++ b/cmake/modules/FindBoost.cmake @@ -1653,7 +1653,7 @@ else() # _Boost_COMPONENT_HEADERS. See the instructions at the top of # _Boost_COMPONENT_DEPENDENCIES. set(_Boost_KNOWN_VERSIONS ${Boost_ADDITIONAL_VERSIONS} - "1.80.0" "1.80" "1.79.0" "1.79" + "1.82.0" "1.82" "1.81.0" "1.81" "1.80.0" "1.80" "1.79.0" "1.79" "1.78.0" "1.78" "1.77.0" "1.77" "1.76.0" "1.76" "1.75.0" "1.75" "1.74.0" "1.74" "1.73.0" "1.73" "1.72.0" "1.72" "1.71.0" "1.71" "1.70.0" "1.70" "1.69.0" "1.69" "1.68.0" "1.68" "1.67.0" "1.67" "1.66.0" "1.66" "1.65.1" "1.65.0" "1.65" diff --git a/install-deps.sh b/install-deps.sh index 8c9e445ffed32..bd11b1a0a4aaf 100755 --- a/install-deps.sh +++ b/install-deps.sh @@ -148,7 +148,7 @@ function install_pkg_on_ubuntu { function install_boost_on_ubuntu { ci_debug "Running install_boost_on_ubuntu() in install-deps.sh" - local ver=1.79 + local ver=1.82 local installed_ver=$(apt -qq list --installed ceph-libboost*-dev 2>/dev/null | grep -e 'libboost[0-9].[0-9]\+-dev' | cut -d' ' -f2 | @@ -163,7 +163,7 @@ function install_boost_on_ubuntu { fi local codename=$1 local project=libboost - local sha1=892ab89e76b91b505ffbf083f6fb7f2a666d4132 + local sha1=2804368f5b807ba8334b0ccfeb8af191edeb996f install_pkg_on_ubuntu \ $project \ $sha1 \ diff --git a/make-dist b/make-dist index 22bf2c98c003b..dfe56cef64fa2 100755 --- a/make-dist +++ b/make-dist @@ -191,8 +191,8 @@ ln -s . $outfile tar cvf $outfile.version.tar $outfile/src/.git_version $outfile/ceph.spec # NOTE: If you change this version number make sure the package is available # at the three URLs referenced below (may involve uploading to download.ceph.com) -boost_version=1.79.0 -download_boost $boost_version 475d589d51a7f8b3ba2ba4eda022b170e562ca3b760ee922c146b6c65856ef39 \ +boost_version=1.82.0 +download_boost $boost_version a6e1ab9b0860e6a2881dd7b21fe9f737a095e5f33a3a874afc6a345228597ee6 \ https://boostorg.jfrog.io/artifactory/main/release/$boost_version/source \ https://download.ceph.com/qa download_liburing 0.7 8e2842cfe947f3a443af301bdd6d034455536c38a455c7a700d0c1ad165a7543 \ diff --git a/src/rgw/rgw_asio_client.cc b/src/rgw/rgw_asio_client.cc index a0ec0bf5c0683..51d43140ba56d 100644 --- a/src/rgw/rgw_asio_client.cc +++ b/src/rgw/rgw_asio_client.cc @@ -39,11 +39,11 @@ int ClientIO::init_env(CephContext *cct) const auto& value = header->value(); if (field == beast::http::field::content_length) { - env.set("CONTENT_LENGTH", value.to_string()); + env.set("CONTENT_LENGTH", std::string(value)); continue; } if (field == beast::http::field::content_type) { - env.set("CONTENT_TYPE", value.to_string()); + env.set("CONTENT_TYPE", std::string(value)); continue; } @@ -62,26 +62,26 @@ int ClientIO::init_env(CephContext *cct) } *dest = '\0'; - env.set(buf, value.to_string()); + env.set(buf, std::string(value)); } int major = request.version() / 10; int minor = request.version() % 10; env.set("HTTP_VERSION", std::to_string(major) + '.' + std::to_string(minor)); - env.set("REQUEST_METHOD", request.method_string().to_string()); + env.set("REQUEST_METHOD", std::string(request.method_string())); // split uri from query auto uri = request.target(); auto pos = uri.find('?'); if (pos != uri.npos) { auto query = uri.substr(pos + 1); - env.set("QUERY_STRING", query.to_string()); + env.set("QUERY_STRING", std::string(query)); uri = uri.substr(0, pos); } - env.set("SCRIPT_URI", uri.to_string()); + env.set("SCRIPT_URI", std::string(uri)); - env.set("REQUEST_URI", request.target().to_string()); + env.set("REQUEST_URI", std::string(request.target())); char port_buf[16]; snprintf(port_buf, sizeof(port_buf), "%d", local_endpoint.port()); diff --git a/win32_deps_build.sh b/win32_deps_build.sh index 8535339e7bcb6..7e6b1e0aa1405 100755 --- a/win32_deps_build.sh +++ b/win32_deps_build.sh @@ -20,8 +20,8 @@ sslDir="${depsToolsetDir}/openssl" sslSrcDir="${depsSrcDir}/openssl" # For now, we'll keep the version number within the file path when not using git. -boostUrl="https://boostorg.jfrog.io/artifactory/main/release/1.79.0/source/boost_1_79_0.tar.gz" -boostSrcDir="${depsSrcDir}/boost_1_79_0" +boostUrl="https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.gz" +boostSrcDir="${depsSrcDir}/boost_1_82_0" boostDir="${depsToolsetDir}/boost" zlibDir="${depsToolsetDir}/zlib" zlibSrcDir="${depsSrcDir}/zlib"