diff --git a/.github/scripts/strategy-matrix/generate.py b/.github/scripts/strategy-matrix/generate.py index 3395751df0..17b4f34491 100755 --- a/.github/scripts/strategy-matrix/generate.py +++ b/.github/scripts/strategy-matrix/generate.py @@ -164,14 +164,16 @@ def generate_strategy_matrix(all: bool, config: Config) -> list: # Add the configuration to the list, with the most unique fields first, # so that they are easier to identify in the GitHub Actions UI, as long # names get truncated. Add Address and Thread (both coupled with UB) sanitizers when the distro is bookworm. - if os['distro_version'] == 'bookworm': + if os['distro_version'] == 'bookworm' and f'{os["compiler_name"]}-{os["compiler_version"]}' in {'gcc-15', 'clang-20'}: # Use medium code model to avoid relocation errors with large binaries # Only for x86-64 (amd64) - ARM64 doesn't support -mcmodel=medium extra_warning_flags = '' linker_flags = '' if architecture['platform'] == 'linux/amd64': + # Add -mcmodel=medium to both compiler AND linker flags + # This is needed because sanitizers create very large binaries cxx_flags += ' -mcmodel=medium' - linker_flags = ' -DCMAKE_EXE_LINKER_FLAGS="-mcmodel=medium" -DCMAKE_SHARED_LINKER_FLAGS="-mcmodel=medium"' + linker_flags = ' -DCMAKE_EXE_LINKER_FLAGS=-mcmodel=medium -DCMAKE_SHARED_LINKER_FLAGS=-mcmodel=medium' # Suppress false positive warnings in GCC with stringop-overflow if os['compiler_name'] == 'gcc': extra_warning_flags += ' -Wno-stringop-overflow' diff --git a/.github/workflows/reusable-build-test-config.yml b/.github/workflows/reusable-build-test-config.yml index 4499041c7b..f1b49f94d0 100644 --- a/.github/workflows/reusable-build-test-config.yml +++ b/.github/workflows/reusable-build-test-config.yml @@ -146,7 +146,7 @@ jobs: if-no-files-found: error - name: Check linking (Linux) - if: ${{ runner.os == 'Linux' }} + if: ${{ runner.os == 'Linux' && input.sanitizers == '' }} working-directory: ${{ inputs.build_dir }} run: | ldd ./rippled diff --git a/external/asan_suppressions.txt b/external/asan_suppressions.txt index 789417b384..b0fb2ed2ac 100644 --- a/external/asan_suppressions.txt +++ b/external/asan_suppressions.txt @@ -1,4 +1,4 @@ # Suppress voilations in Boost libraries -interceptor_via_lib:libboost_.* +interceptor_via_lib:^libboost_.* # Suprpress voilations in external code interceptor_name:^external/* diff --git a/external/tsan_suppressions.txt b/external/tsan_suppressions.txt index e69de29bb2..66a144180d 100644 --- a/external/tsan_suppressions.txt +++ b/external/tsan_suppressions.txt @@ -0,0 +1 @@ +called_from_lib:^libboost_.* \ No newline at end of file