summaryrefslogtreecommitdiff
path: root/tools/bugpoint
diff options
context:
space:
mode:
authorBrian Gaeke <gaeke@uiuc.edu>2003-11-18 06:31:17 +0000
committerBrian Gaeke <gaeke@uiuc.edu>2003-11-18 06:31:17 +0000
commitc8db76c647c93a79f66b094a2db3eaccb14cbae4 (patch)
tree47746797fb52e0af6d7a22fcab42fd32ef536396 /tools/bugpoint
parent17a51cecfdf38bf268f6d5b426f760650e8471ad (diff)
downloadllvm-c8db76c647c93a79f66b094a2db3eaccb14cbae4.tar.gz
llvm-c8db76c647c93a79f66b094a2db3eaccb14cbae4.tar.bz2
llvm-c8db76c647c93a79f66b094a2db3eaccb14cbae4.tar.xz
Only use -Wl,-R. if HAVE_LINK_R.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10066 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/bugpoint')
-rw-r--r--tools/bugpoint/ToolRunner.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/bugpoint/ToolRunner.cpp b/tools/bugpoint/ToolRunner.cpp
index 50a9ad21c8..0f2e13e20f 100644
--- a/tools/bugpoint/ToolRunner.cpp
+++ b/tools/bugpoint/ToolRunner.cpp
@@ -13,6 +13,7 @@
#define DEBUG_TYPE "toolrunner"
#include "llvm/Support/ToolRunner.h"
+#include "Config/config.h" // for HAVE_LINK_R
#include "Support/Debug.h"
#include "Support/FileUtilities.h"
#include <iostream>
@@ -299,7 +300,9 @@ int GCC::ExecuteProgram(const std::string &ProgramFile,
GCCArgs.push_back(OutputBinary.c_str()); // Output to the right file...
GCCArgs.push_back("-lm"); // Hard-code the math library...
GCCArgs.push_back("-O2"); // Optimize the program a bit...
+#if defined (HAVE_LINK_R)
GCCArgs.push_back("-Wl,-R."); // Search this dir for .so files
+#endif
GCCArgs.push_back(0); // NULL terminator
std::cout << "<gcc>" << std::flush;