aboutsummaryrefslogtreecommitdiff
path: root/lib/Support/Triple.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2011-04-19 20:19:27 +0000
committerDaniel Dunbar <daniel@zuster.org>2011-04-19 20:19:27 +0000
commit0dde4c00ee3b3514fcbabb7bca6b1f1189c4c5b9 (patch)
tree29a20fa88cfbb881a0260635d2c42aded84accdd /lib/Support/Triple.cpp
parent567cac0c511c2361ddb76eb4b8d49d306107a921 (diff)
ADT/Triple: Add support for more explicit "osx" and "ios" OS names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129798 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/Triple.cpp')
-rw-r--r--lib/Support/Triple.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Support/Triple.cpp b/lib/Support/Triple.cpp
index 53ca48f846..2679481b47 100644
--- a/lib/Support/Triple.cpp
+++ b/lib/Support/Triple.cpp
@@ -99,10 +99,12 @@ const char *Triple::getOSTypeName(OSType Kind) {
case Darwin: return "darwin";
case DragonFly: return "dragonfly";
case FreeBSD: return "freebsd";
+ case IOS: return "ios";
case Linux: return "linux";
case Lv2: return "lv2";
case MinGW32: return "mingw32";
case NetBSD: return "netbsd";
+ case OSX: return "osx";
case OpenBSD: return "openbsd";
case Psp: return "psp";
case Solaris: return "solaris";
@@ -314,6 +316,8 @@ Triple::OSType Triple::ParseOS(StringRef OSName) {
return DragonFly;
else if (OSName.startswith("freebsd"))
return FreeBSD;
+ else if (OSName.startswith("ios"))
+ return IOS;
else if (OSName.startswith("linux"))
return Linux;
else if (OSName.startswith("lv2"))
@@ -322,6 +326,8 @@ Triple::OSType Triple::ParseOS(StringRef OSName) {
return MinGW32;
else if (OSName.startswith("netbsd"))
return NetBSD;
+ else if (OSName.startswith("osx"))
+ return OSX;
else if (OSName.startswith("openbsd"))
return OpenBSD;
else if (OSName.startswith("psp"))