rippled icon indicating copy to clipboard operation
rippled copied to clipboard

Updates Conan dependencies: Boost

Open bthomee opened this issue 11 months ago • 1 comments

High Level Overview of Change

This PR updates Boost to version 1.86.0. Only minor changes were necessary to the code.

Context of Change

Dependency scanning revealed that current dependencies are out of date. Updating dependencies allows us to take advantage of bug fixes, new features, and/or security improvements.

Type of Change

  • [X] Refactor (non-breaking change that only restructures code)

bthomee avatar Jan 30 '25 14:01 bthomee

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :warning: Please upload report for BASE (develop@e7a7bb8). Learn more about missing BASE report. :warning: Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff            @@
##             develop   #5264   +/-   ##
=========================================
  Coverage           ?   78.8%           
=========================================
  Files              ?     814           
  Lines              ?   71259           
  Branches           ?    8342           
=========================================
  Hits               ?   56162           
  Misses             ?   15097           
  Partials           ?       0           
Files with missing lines Coverage Δ
include/xrpl/basics/Log.h 71.4% <ø> (ø)
src/libxrpl/basics/FileUtilities.cpp 71.4% <100.0%> (ø)
src/xrpld/app/main/Application.cpp 69.2% <ø> (ø)
src/xrpld/app/main/Main.cpp 79.0% <ø> (ø)

Impacted file tree graph

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Mar 26 '25 18:03 codecov[bot]

I investigated the link error due to duplicate definition of __cxa_allocate_exception. We have three options to fix it:

  • Do not upgrade to 1.86.0 ; instead upgrade only to 1.84.0 (I recommend against, we will eventually need to upgrade higher than 1.84.0 anyway)

  • Disable the use of boost in soci, with a one-line change in our conanfile.py

diff --git a/conanfile.py b/conanfile.py
index 174d723d95..a98c1b0e8a 100644
--- a/conanfile.py
+++ b/conanfile.py
@@ -98,6 +98,7 @@ class Xrpl(ConanFile):
                 self.version = match.group(1)

     def configure(self):
+        self.options["soci"].with_boost = False
         if self.settings.compiler == 'apple-clang':
             self.options['boost'].visibility = 'global'
  • Switch our external/soci to use boost headers only. Incidentally, that's what "official" soci does
diff --git a/external/soci/conanfile.py b/external/soci/conanfile.py
index 0e5257bd7b..fe4c54e53e 100644
--- a/external/soci/conanfile.py
+++ b/external/soci/conanfile.py
@@ -154,7 +154,7 @@ class SociConan(ConanFile):
         self.cpp_info.components["soci_core"].set_property("cmake_target_name", "SOCI::soci_core{}".format(target_suffix))
         self.cpp_info.components["soci_core"].libs = ["{}soci_core{}".format(lib_prefix, lib_suffix)]
         if self.options.with_boost:
-            self.cpp_info.components["soci_core"].requires.append("boost::boost")
+            self.cpp_info.components["soci_core"].requires.append("boost::headers")

         # soci_empty
         if self.options.empty:

I think the last option is probably best.

Bronek avatar Jul 24 '25 10:07 Bronek

instrumentation error should be fixed with https://github.com/XRPLF/rippled/pull/5607 , or by cherry-picking https://github.com/XRPLF/rippled/pull/5606/commits/2ea247bb9c3d57a9e665c868ff1019f58e313ac5

Bronek avatar Jul 24 '25 12:07 Bronek