Windows: canonicalise the default windows triple
authorSaleem Abdulrasool <compnerd@compnerd.org>
Sat, 29 Mar 2014 01:08:53 +0000 (01:08 +0000)
committerSaleem Abdulrasool <compnerd@compnerd.org>
Sat, 29 Mar 2014 01:08:53 +0000 (01:08 +0000)
Canonicalise the default triple that is used on Windows.  This should hopefully
fix the MSVC buildbots.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@205070 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Support/Windows/Host.inc
tools/llvm-config/llvm-config.cpp

index 7bda89dc49c7fa2b0d521c0a5139475f4664a120..0c02bf9368148e3fd832f4b30a524fdb22e31efe 100644 (file)
@@ -18,5 +18,5 @@
 using namespace llvm;
 
 std::string sys::getDefaultTargetTriple() {
-  return LLVM_DEFAULT_TARGET_TRIPLE;
+  return Triple::normalize(LLVM_DEFAULT_TARGET_TRIPLE);
 }
index 8a42aa33cc15309daa18217c2ac30cb9e7c4e7a8..ed1c8c3b2ae781d50600301437ff86412e1f4f88 100644 (file)
@@ -20,6 +20,7 @@
 #include "llvm/ADT/STLExtras.h"
 #include "llvm/ADT/StringMap.h"
 #include "llvm/ADT/StringRef.h"
+#include "llvm/ADT/Triple.h"
 #include "llvm/ADT/Twine.h"
 #include "llvm/Config/config.h"
 #include "llvm/Config/llvm-config.h"
@@ -311,7 +312,7 @@ int main(int argc, char **argv) {
       } else if (Arg == "--targets-built") {
         OS << LLVM_TARGETS_BUILT << '\n';
       } else if (Arg == "--host-target") {
-        OS << LLVM_DEFAULT_TARGET_TRIPLE << '\n';
+        OS << Triple::normalize(LLVM_DEFAULT_TARGET_TRIPLE) << '\n';
       } else if (Arg == "--build-mode") {
         OS << build_mode << '\n';
       } else if (Arg == "--assertion-mode") {