[llvm-commits] [llvm] r76432 - /llvm/trunk/tools/bugpoint/ToolRunner.cpp
David Goodwin
david_goodwin at apple.com
Mon Jul 20 10:15:03 PDT 2009
Author: david_goodwin
Date: Mon Jul 20 12:15:03 2009
New Revision: 76432
URL: http://llvm.org/viewvc/llvm-project?rev=76432&view=rev
Log:
For remote execution, must cd to the executable directory since the exe expects to find a dylib in the CWD ('.').
Modified:
llvm/trunk/tools/bugpoint/ToolRunner.cpp
Modified: llvm/trunk/tools/bugpoint/ToolRunner.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/bugpoint/ToolRunner.cpp?rev=76432&r1=76431&r2=76432&view=diff
==============================================================================
--- llvm/trunk/tools/bugpoint/ToolRunner.cpp (original)
+++ llvm/trunk/tools/bugpoint/ToolRunner.cpp Mon Jul 20 12:15:03 2009
@@ -688,7 +688,6 @@
std::vector<const char*> ProgramArgs;
- std::string Exec;
if (RemoteClientPath.isEmpty())
ProgramArgs.push_back(OutputBinary.c_str());
else {
@@ -704,10 +703,12 @@
ProgramArgs.push_back(RemoteExtra.c_str());
}
- // Full path to the binary
+ // Full path to the binary. We need to cd to the exec directory because
+ // there is a dylib there that the exec expects to find in the CWD
char* env_pwd = getenv("PWD");
+ std::string Exec = "cd ";
Exec += env_pwd;
- Exec += "/";
+ Exec += "; ./";
Exec += OutputBinary.c_str();
ProgramArgs.push_back(Exec.c_str());
}
More information about the llvm-commits
mailing list