From d4b033958e8a93d120dea1463aee081526e55ad1 Mon Sep 17 00:00:00 2001 From: Pratik Mankawde Date: Wed, 19 Nov 2025 18:05:39 +0000 Subject: [PATCH] removed static linking. Signed-off-by: Pratik Mankawde --- .github/scripts/strategy-matrix/generate.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/scripts/strategy-matrix/generate.py b/.github/scripts/strategy-matrix/generate.py index a6268bff0a..1b31276631 100755 --- a/.github/scripts/strategy-matrix/generate.py +++ b/.github/scripts/strategy-matrix/generate.py @@ -184,12 +184,12 @@ def generate_strategy_matrix(all: bool, config: Config) -> list: # Use default linker (bfd/ld) which is more lenient with mixed code models cmake_args += ' -Duse_mold=OFF -Duse_gold=OFF -Duse_lld=OFF' # Add linker flags for Sanitizers - linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="{linker_relocation_flags} -static-libasan -static-libtsan -static-libubsan -fsanitize=address,{sanitizers_flags}"' - linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="{linker_relocation_flags} -static-libasan -static-libtsan -static-libubsan -fsanitize=address,{sanitizers_flags}"' + linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="{linker_relocation_flags} -fsanitize=address,{sanitizers_flags}"' + linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="{linker_relocation_flags} -fsanitize=address,{sanitizers_flags}"' elif os['compiler_name'] == 'clang': sanitizers_flags = f'{sanitizers_flags},signed-integer-overflow,unsigned-integer-overflow' - linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="-fsanitize=address,{sanitizers_flags} -static-libsan"' - linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="-fsanitize=address,{sanitizers_flags} -static-libsan"' + linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="-fsanitize=address,{sanitizers_flags}"' + linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="-fsanitize=address,{sanitizers_flags}"' # Sanitizers recommend minimum of -O1 for reasonable performance if "-O0" in cxx_flags: @@ -221,12 +221,12 @@ def generate_strategy_matrix(all: bool, config: Config) -> list: cxx_flags = cxx_flags.replace('-mcmodel=large', '-mcmodel=medium') linker_relocation_flags = linker_relocation_flags.replace('-mcmodel=large', '-mcmodel=medium') # Add linker flags for Sanitizers - linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="{linker_relocation_flags} -static-libasan -static-libtsan -static-libubsan -fsanitize=thread,{sanitizers_flags}"' - linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="{linker_relocation_flags} -static-libasan -static-libtsan -static-libubsan -fsanitize=thread,{sanitizers_flags}"' + linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="{linker_relocation_flags} -fsanitize=thread,{sanitizers_flags}"' + linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="{linker_relocation_flags} -fsanitize=thread,{sanitizers_flags}"' elif os['compiler_name'] == 'clang': cxx_flags += ' -fsanitize-blacklist=$GITHUB_WORKSPACE/external/sanitizer-blacklist.txt' - linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="-fsanitize=thread,{sanitizers_flags} -static-libsan"' - linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="-fsanitize=thread,{sanitizers_flags} -static-libsan"' + linker_flags += f' -DCMAKE_EXE_LINKER_FLAGS="-fsanitize=thread,{sanitizers_flags}"' + linker_flags += f' -DCMAKE_SHARED_LINKER_FLAGS="-fsanitize=thread,{sanitizers_flags}"' # Note: We use $GITHUB_WORKSPACE environment variable which will be expanded by the shell # before CMake processes it. This ensures the compiler receives an absolute path.