refactor: Update to Boost 1.88 (#5570)

This updates Boost to 1.88, which is needed because Clio wants to move to 1.88 as that fixes several ASAN false positives around coroutine usage. In order for Clio to move to newer boost, libXRPL needs to move too. Hence the changes in this PR. A lot has changed between 1.83 and 1.88 so there are lots of changes in the diff, especially in regards to Boost.Asio and coroutines in particular.
This commit is contained in:
Alex Kremer
2025-08-27 10:34:50 +01:00
committed by GitHub
parent 808c86663c
commit 1506e65558
78 changed files with 871 additions and 516 deletions

View File

@@ -33,6 +33,7 @@
#include <boost/algorithm/string/predicate.hpp>
#include <boost/asio.hpp>
#include <boost/asio/io_context.hpp>
#include <boost/asio/ssl.hpp>
#include <boost/beast/core/multi_buffer.hpp>
#include <boost/beast/http.hpp>
@@ -165,12 +166,11 @@ class ServerStatus_test : public beast::unit_test::suite,
{
using namespace boost::asio;
using namespace boost::beast::http;
io_service& ios = get_io_service();
io_context& ios = get_io_context();
ip::tcp::resolver r{ios};
boost::beast::multi_buffer sb;
auto it = r.async_resolve(
ip::tcp::resolver::query{host, std::to_string(port)}, yield[ec]);
auto it = r.async_resolve(host, std::to_string(port), yield[ec]);
if (ec)
return;
@@ -476,12 +476,11 @@ class ServerStatus_test : public beast::unit_test::suite,
auto req_string = boost::lexical_cast<std::string>(req);
req_string.erase(req_string.find_last_of("13"), std::string::npos);
io_service& ios = get_io_service();
io_context& ios = get_io_context();
ip::tcp::resolver r{ios};
boost::beast::multi_buffer sb;
auto it = r.async_resolve(
ip::tcp::resolver::query{*ip, std::to_string(*port)}, yield[ec]);
auto it = r.async_resolve(*ip, std::to_string(*port), yield[ec]);
if (!BEAST_EXPECTS(!ec, ec.message()))
return;
@@ -610,14 +609,13 @@ class ServerStatus_test : public beast::unit_test::suite,
env.app().config()["port_rpc"].get<std::string>("ip").value();
boost::system::error_code ec;
io_service& ios = get_io_service();
io_context& ios = get_io_context();
ip::tcp::resolver r{ios};
Json::Value jr;
jr[jss::method] = "server_info";
auto it = r.async_resolve(
ip::tcp::resolver::query{ip, std::to_string(port)}, yield[ec]);
auto it = r.async_resolve(ip, std::to_string(port), yield[ec]);
BEAST_EXPECT(!ec);
std::vector<std::pair<ip::tcp::socket, boost::beast::multi_buffer>>
@@ -681,7 +679,7 @@ class ServerStatus_test : public beast::unit_test::suite,
resp["Upgrade"] == "websocket");
BEAST_EXPECT(
resp.find("Connection") != resp.end() &&
resp["Connection"] == "Upgrade");
boost::iequals(resp["Connection"], "upgrade"));
}
void
@@ -728,11 +726,10 @@ class ServerStatus_test : public beast::unit_test::suite,
env.app().config()["port_ws"].get<std::string>("ip").value();
boost::system::error_code ec;
io_service& ios = get_io_service();
io_context& ios = get_io_context();
ip::tcp::resolver r{ios};
auto it = r.async_resolve(
ip::tcp::resolver::query{ip, std::to_string(port)}, yield[ec]);
auto it = r.async_resolve(ip, std::to_string(port), yield[ec]);
if (!BEAST_EXPECT(!ec))
return;