Author: Mitch Phillips Date: 2020-12-16T11:59:10-08:00 New Revision: 30d292ddbb7ec84b422738cf52ee0cf49b0369f3
URL: https://github.com/llvm/llvm-project/commit/30d292ddbb7ec84b422738cf52ee0cf49b0369f3 DIFF: https://github.com/llvm/llvm-project/commit/30d292ddbb7ec84b422738cf52ee0cf49b0369f3.diff LOG: [sanitizer-common] Pickup llvm-symbolizer from $OUT/bin IFF exists. Fix-forward for D93352. Slight rework of the same idea, pickup the external symbolizer from the binary directory iff it exists. Added: Modified: compiler-rt/test/sanitizer_common/lit.common.cfg.py compiler-rt/test/sanitizer_common/lit.site.cfg.py.in Removed: ################################################################################ diff --git a/compiler-rt/test/sanitizer_common/lit.common.cfg.py b/compiler-rt/test/sanitizer_common/lit.common.cfg.py index f7c526b6b37b..1f037c00eb15 100644 --- a/compiler-rt/test/sanitizer_common/lit.common.cfg.py +++ b/compiler-rt/test/sanitizer_common/lit.common.cfg.py @@ -46,10 +46,9 @@ # If the user has a poisoned *SAN_SYMBOLIZER_PATH (like what's setup by # build/envsetup.sh on Android), then they can end up with an out-of-date # symbolizer for the tests. Ensure they get the one from the recent build tree. -symbolizer_path="''" -if len(config.binary_path): - symbolizer_path = os.path.join(config.binary_path, "llvm-symbolizer") -default_tool_options += ['external_symbolizer_path=' + symbolizer_path] +symbolizer_path = os.path.join(config.binary_path, "bin", "llvm-symbolizer") +if os.path.exists(symbolizer_path): + default_tool_options += ['external_symbolizer_path=' + symbolizer_path] default_tool_options_str = ':'.join(default_tool_options) if default_tool_options_str: diff --git a/compiler-rt/test/sanitizer_common/lit.site.cfg.py.in b/compiler-rt/test/sanitizer_common/lit.site.cfg.py.in index 3ff7c44aeab4..fa7e54e51e27 100644 --- a/compiler-rt/test/sanitizer_common/lit.site.cfg.py.in +++ b/compiler-rt/test/sanitizer_common/lit.site.cfg.py.in @@ -5,7 +5,7 @@ config.name_suffix = "@CONFIG_NAME@" config.tool_name = "@SANITIZER_COMMON_LIT_TEST_MODE@" config.target_cflags = "@SANITIZER_COMMON_TEST_TARGET_CFLAGS@" config.target_arch = "@SANITIZER_COMMON_TEST_TARGET_ARCH@" -config.binary_path = "@CMAKE_RUNTIME_OUTPUT_DIRECTORY@" +config.binary_path = "@LLVM_BINARY_DIR@" # Load common config for all compiler-rt lit tests. lit_config.load_config(config, "@COMPILER_RT_BINARY_DIR@/test/lit.common.configured") _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits