diff options
author | Chris Lattner <sabre@nondot.org> | 2003-04-21 19:53:24 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-04-21 19:53:24 +0000 |
commit | d34a51dbbe84562e054811f70705f66177848096 (patch) | |
tree | 8b0647052ac3fd69e5eca398924ba085dbb8857c /tools/gccld/gccld.cpp | |
parent | 085c801dee6869e657981750e723fe5cd1482c55 (diff) |
Add support for allowing the user to extend the GCCLD searchpath
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5825 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/gccld/gccld.cpp')
-rw-r--r-- | tools/gccld/gccld.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/gccld/gccld.cpp b/tools/gccld/gccld.cpp index 90cebb4df0..1d61d13a63 100644 --- a/tools/gccld/gccld.cpp +++ b/tools/gccld/gccld.cpp @@ -294,6 +294,10 @@ int main(int argc, char **argv) { if (Composite.get() == 0) return PrintAndReturn(argv[0], ErrorMessage); + // If the user specied an extra search path in their environment, respect it. + if (char *SearchPath = getenv("LLVM_LIB_SEARCH_PATH")) + LibPaths.push_back(SearchPath); + for (unsigned i = 1; i < InputFilenames.size(); ++i) { std::auto_ptr<Module> M(LoadObject(InputFilenames[i], ErrorMessage)); if (M.get() == 0) |