Search for llvm-symbolizer binary in the same directory as argv[0], before

looking for it along $PATH. This allows installs of LLVM tools outside of
$PATH to find the symbolizer and produce pretty backtraces if they crash.

llvm-svn: 272232
This commit is contained in:
Richard Smith
2016-06-09 00:53:21 +00:00
parent 6d1d27542f
commit 2ad6d48b0c
41 changed files with 87 additions and 73 deletions

View File

@@ -1736,7 +1736,7 @@ static void DumpInput(StringRef file) {
int main(int argc, char **argv) {
// Print a stack trace if we signal out.
sys::PrintStackTraceOnErrorSignal();
sys::PrintStackTraceOnErrorSignal(argv[0]);
PrettyStackTraceProgram X(argc, argv);
llvm_shutdown_obj Y; // Call llvm_shutdown() on exit.