From 91960f4abb2eb2f1f231b01e625bde83c5191315 Mon Sep 17 00:00:00 2001 From: Joerg Sonnenberger Date: Thu, 26 Jan 2012 21:56:28 +0000 Subject: Keep track of the original target the user specified before normalization. This used to be captured in DefaultTargetTriple and is used for the (optional) $triple-$tool lookup for cross-compilation. Do this properly by making it an attribute of the toolchain and use it in combination with the computed triple as index for the toolchain lookup. llvm-svn: 149083 --- clang/lib/Driver/ToolChain.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'clang/lib/Driver/ToolChain.cpp') diff --git a/clang/lib/Driver/ToolChain.cpp b/clang/lib/Driver/ToolChain.cpp index c0c9c504b6d..52038d2327f 100644 --- a/clang/lib/Driver/ToolChain.cpp +++ b/clang/lib/Driver/ToolChain.cpp @@ -20,8 +20,9 @@ using namespace clang::driver; using namespace clang; -ToolChain::ToolChain(const Driver &D, const llvm::Triple &T) - : D(D), Triple(T) { +ToolChain::ToolChain(const Driver &D, const llvm::Triple &T, + const std::string &UserTriple) + : D(D), Triple(T), UserTriple(UserTriple) { } ToolChain::~ToolChain() { -- cgit v1.2.3