Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update boost to v1.81.0 #648

Merged
merged 2 commits into from
Dec 20, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmake/configs/default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ if(MINGW)
# https://github.com/boostorg/build/issues/301
hunter_default_version(Boost VERSION 1.64.0)
else()
hunter_default_version(Boost VERSION 1.80.0)
hunter_default_version(Boost VERSION 1.81.0)
endif()

hunter_default_version(BoostCompute VERSION 0.5-p0)
Expand Down
1 change: 1 addition & 0 deletions cmake/modules/hunter_get_boost_libs.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ function(hunter_get_boost_libs)
hunter_append_component(${common_args} COMPONENT thread SINCE 1.25.0)
hunter_append_component(${common_args} COMPONENT timer SINCE 1.9.0)
hunter_append_component(${common_args} COMPONENT type_erasure SINCE 1.60.0)
hunter_append_component(${common_args} COMPONENT url SINCE 1.81.0)
hunter_append_component(${common_args} COMPONENT wave SINCE 1.33.0)
# DOCUMENTATION_END }

Expand Down
16 changes: 15 additions & 1 deletion cmake/projects/Boost/ci/matrix.json
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,20 @@
{ "example": "Boost-thread", "toolchain": "nmake-vs-16-2019-win64-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
// { "example": "Boost-thread", "toolchain": "vs-16-2019-win64-sdk-10-0-18362-0-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
{ "example": "Boost-thread", "toolchain": "mingw-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
{ "example": "Boost-thread", "toolchain": "msys-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" }
{ "example": "Boost-thread", "toolchain": "msys-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },

// { "example": "Boost-url", "toolchain": "clang-cxx17", "os": "ubuntu-20.04", "python": "3.8", "script": "build.sh" },
{ "example": "Boost-url", "toolchain": "gcc-7-cxx17", "os": "ubuntu-20.04", "python": "3.8", "script": "build.sh" },
// { "example": "Boost-url", "toolchain": "gcc-8-cxx17-fpic", "os": "ubuntu-20.04", "python": "3.8", "script": "build.sh" },
// { "example": "Boost-url", "toolchain": "gcc-9-cxx17-fpic", "os": "ubuntu-20.04", "python": "3.8", "script": "build.sh" },
{ "example": "Boost-url", "toolchain": "android-ndk-r17-api-24-arm64-v8a-clang-libcxx14", "os": "ubuntu-20.04", "python": "3.8", "script": "build.sh" },
// { "example": "Boost-url", "toolchain": "osx-10-15-make-cxx14", "os": "macos-10.15", "python": "3.8", "script": "build.sh" },
// { "example": "Boost-url", "toolchain": "osx-12-3-arch-universal2-cxx17", "os": "macos-12", "python": "3.8", "script": "build.sh" },
{ "example": "Boost-url", "toolchain": "ios-nocodesign-15-5-arm64-cxx17", "os": "macos-12", "python": "3.8", "script": "build.sh" },
// { "example": "Boost-url", "toolchain": "ninja-vs-16-2019-win64-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
{ "example": "Boost-url", "toolchain": "nmake-vs-16-2019-win64-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
// { "example": "Boost-url", "toolchain": "vs-16-2019-win64-sdk-10-0-18362-0-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
{ "example": "Boost-url", "toolchain": "mingw-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" },
{ "example": "Boost-url", "toolchain": "msys-cxx17", "os": "windows-2019", "python": "3.8", "script": "build.cmd" }

NeroBurner marked this conversation as resolved.
Show resolved Hide resolved
]
11 changes: 11 additions & 0 deletions cmake/projects/Boost/hunter.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,17 @@ hunter_add_version(
5463e5380ccd1564e57747969c9dcc852b82b237
)

hunter_add_version(
PACKAGE_NAME
Boost
VERSION
"1.81.0"
URL
"https://boostorg.jfrog.io/artifactory/main/release/1.81.0/source/boost_1_81_0.7z"
SHA1
90bef80787606e1f4022a877073b2346636fdba3
)

# up until 1.63 sourcefourge was used, base url https://downloads.sourceforge.net/project/boost/boost
hunter_add_version(
PACKAGE_NAME
Expand Down
22 changes: 22 additions & 0 deletions cmake/projects/Boost/url/hunter.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Copyright (c) 2013, Ruslan Baratov
# All rights reserved.

# !!! DO NOT PLACE HEADER GUARDS HERE !!!

include(hunter_download)
include(hunter_pick_scheme)

hunter_pick_scheme(
DEFAULT
url_sha1_boost_library
IPHONEOS
url_sha1_boost_ios_library
)

hunter_download(
PACKAGE_NAME
Boost
PACKAGE_COMPONENT
url
PACKAGE_INTERNAL_DEPS_ID "50"
)
18 changes: 18 additions & 0 deletions examples/Boost-url/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Copyright (c) 2013, Ruslan Baratov
# All rights reserved.

cmake_minimum_required(VERSION 3.0)

set(Boost_DEBUG ON CACHE BOOLEAN "")

# Emulate HunterGate:
# * https://github.com/hunter-packages/gate
include("../common.cmake")

project(download-boost)

hunter_add_package(Boost COMPONENTS url)
find_package(Boost CONFIG REQUIRED url)

add_executable(foo foo.cpp)
target_link_libraries(foo PUBLIC Boost::url)
35 changes: 35 additions & 0 deletions examples/Boost-url/foo.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@

#include <boost/url.hpp>
#include <iostream>

using namespace boost::urls;

int main() {
// example taken from here: https://www.boost.org/doc/libs/1_81_0/libs/url/doc/html/url/overview.html#url.overview.quick_look.accessing
url_view u( "https://user:pass@example.com:443/path/to/my%2dfile.txt?id=42&name=John%20Doe+Jingleheimer%2DSchmidt#page%20anchor" );

assert(u.scheme() == "https");
assert(u.authority().buffer() == "user:pass@example.com:443");
assert(u.userinfo() == "user:pass");
assert(u.user() == "user");
assert(u.password() == "pass");
assert(u.host() == "example.com");
assert(u.port() == "443");
assert(u.path() == "/path/to/my-file.txt");
assert(u.query() == "id=42&name=John Doe+Jingleheimer-Schmidt");
assert(u.fragment() == "page anchor");

std::cout <<
"url : " << u << "\n"
"scheme : " << u.scheme() << "\n"
"authority : " << u.encoded_authority() << "\n"
"userinfo : " << u.encoded_userinfo() << "\n"
"user : " << u.encoded_user() << "\n"
"password : " << u.encoded_password() << "\n"
"host : " << u.encoded_host() << "\n"
"port : " << u.port() << "\n"
"path : " << u.encoded_path() << "\n"
"query : " << u.encoded_query() << "\n"
"fragment : " << u.encoded_fragment() << "\n";

}