symbolizer-path
authorLLVM Packaging Team <pkg-llvm-team@lists.alioth.debian.org>
Sun, 3 Feb 2019 16:27:51 +0000 (16:27 +0000)
committerSylvestre Ledru <sylvestre@debian.org>
Sun, 3 Feb 2019 16:27:51 +0000 (16:27 +0000)
===================================================================

Gbp-Pq: Name symbolizer-path.diff

compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc

index d74a6f44ee6bf6c31b7e8ac345ccef50a3d6e34d..3491027e9130817ed7d384ca3be695d467faa5b1 100644 (file)
 #include "sanitizer_symbolizer_internal.h"
 #include "sanitizer_symbolizer_libbacktrace.h"
 #include "sanitizer_symbolizer_mac.h"
+#include "llvm/Config/llvm-config.h" // for LLVM_VERSION_MAJOR
+
+#define TOSTR2(X) #X
+#define TOSTR(X) TOSTR2(X)
 
 #include <dlfcn.h>   // for dlsym()
 #include <errno.h>
@@ -481,7 +485,7 @@ static SymbolizerTool *ChooseExternalSymbolizer(LowLevelAllocator *allocator) {
     return new(*allocator) AtosSymbolizer(found_path, allocator);
   }
 #endif  // SANITIZER_MAC
-  if (const char *found_path = FindPathToBinary("llvm-symbolizer")) {
+  if (const char *found_path = "/usr/bin/llvm-symbolizer-" TOSTR(LLVM_VERSION_MAJOR)) {
     VReport(2, "Using llvm-symbolizer found at: %s\n", found_path);
     return new(*allocator) LLVMSymbolizer(found_path, allocator);
   }