]> granicus.if.org Git - clang/commitdiff
Support EFI target triple, from Carl Norum!
authorDouglas Gregor <dgregor@apple.com>
Tue, 1 Feb 2011 15:06:18 +0000 (15:06 +0000)
committerDouglas Gregor <dgregor@apple.com>
Tue, 1 Feb 2011 15:06:18 +0000 (15:06 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124660 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Basic/Targets.cpp

index 19e758747b0c1395ae295766d84cdc9de0b21435..68881177255cd78719bdf0fd807f249a7d41dd77 100644 (file)
@@ -2675,7 +2675,10 @@ static TargetInfo *AllocateTarget(const std::string &T) {
     case llvm::Triple::MinGW64:
       return new MinGWX86_64TargetInfo(T);
     case llvm::Triple::Win32:   // This is what Triple.h supports now.
-      return new VisualStudioWindowsX86_64TargetInfo(T);
+      if (Triple.getEnvironment() == llvm::Triple::MachO)
+        return new DarwinX86_64TargetInfo(T);
+      else
+        return new VisualStudioWindowsX86_64TargetInfo(T);
     default:
       return new X86_64TargetInfo(T);
     }