Patches 1-2 are just rebased from the earlier version for clang 3.8, no changes in surrounding code there. Patch 3 is necessary to fix a regression in assembling standalone assembly files in 3.9. Patch 4 makes clang work in MSVC mode with the MSVC SDK for ARM (to simplify testing of the toolchain in that mode).
46 lines
1.6 KiB
Diff
46 lines
1.6 KiB
Diff
From 4139cf38b1a16aa49a7b9eed79b0cccec1a70ec8 Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Hugo=20Beauz=C3=A9e-Luyssen?= <hugo@beauzee.fr>
|
|
Date: Mon, 2 May 2016 15:58:31 +0200
|
|
Subject: [PATCH 2/4] Manually revert 0e2452f3055e2e2cad06a55c5ca9c2be13404781
|
|
|
|
This re-enables mingw detection
|
|
---
|
|
lib/Driver/MinGWToolChain.cpp | 14 ++++----------
|
|
1 file changed, 4 insertions(+), 10 deletions(-)
|
|
|
|
diff --git a/lib/Driver/MinGWToolChain.cpp b/lib/Driver/MinGWToolChain.cpp
|
|
index 938440b..a1dc25b 100644
|
|
--- a/lib/Driver/MinGWToolChain.cpp
|
|
+++ b/lib/Driver/MinGWToolChain.cpp
|
|
@@ -66,23 +66,17 @@ MinGW::MinGW(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
|
|
: ToolChain(D, Triple, Args) {
|
|
getProgramPaths().push_back(getDriver().getInstalledDir());
|
|
|
|
-// In Windows there aren't any standard install locations, we search
|
|
-// for gcc on the PATH. In Linux the base is always /usr.
|
|
-#ifdef LLVM_ON_WIN32
|
|
+ // On Windows if there is no sysroot we search for gcc on the PATH.
|
|
if (getDriver().SysRoot.size())
|
|
Base = getDriver().SysRoot;
|
|
+#ifdef LLVM_ON_WIN32
|
|
else if (llvm::ErrorOr<std::string> GPPName =
|
|
llvm::sys::findProgramByName("gcc"))
|
|
Base = llvm::sys::path::parent_path(
|
|
llvm::sys::path::parent_path(GPPName.get()));
|
|
- else
|
|
- Base = llvm::sys::path::parent_path(getDriver().getInstalledDir());
|
|
-#else
|
|
- if (getDriver().SysRoot.size())
|
|
- Base = getDriver().SysRoot;
|
|
- else
|
|
- Base = "/usr";
|
|
#endif
|
|
+ if (!Base.size())
|
|
+ Base = llvm::sys::path::parent_path(getDriver().getInstalledDir());
|
|
|
|
Base += llvm::sys::path::get_separator();
|
|
findGccLibDir();
|
|
--
|
|
2.7.4
|
|
|