aboutsummaryrefslogtreecommitdiff
path: root/libbutl/target-triplet.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2017-12-04 15:28:42 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2017-12-04 15:28:42 +0200
commit8de41f3d54c265b9fcbcd3df943b1049f17e662e (patch)
treea4f4c947f4ce5dddcc4139a572e66672de19acf3 /libbutl/target-triplet.cxx
parentae93579cf9b706a79085e5d694785a0a1189b60e (diff)
Recognize and handle Clang's <cpu>-pc-windows-msvc target triplet
Diffstat (limited to 'libbutl/target-triplet.cxx')
-rw-r--r--libbutl/target-triplet.cxx11
1 files changed, 8 insertions, 3 deletions
diff --git a/libbutl/target-triplet.cxx b/libbutl/target-triplet.cxx
index 88a4262..dfd93b4 100644
--- a/libbutl/target-triplet.cxx
+++ b/libbutl/target-triplet.cxx
@@ -83,7 +83,8 @@ namespace butl
{
// See if this is one of the well-known non-vendors.
//
- if (s.compare (f, n, "linux") == 0 ||
+ if (s.compare (f, n, "linux") == 0 ||
+ s.compare (f, n, "windows") == 0 ||
s.compare (f, n, "kfreebsd") == 0)
{
l = f - 1;
@@ -134,9 +135,13 @@ namespace butl
class_ = "linux";
else if (vendor == "apple" && system == "darwin")
class_ = "macos";
- else if (system == "freebsd" || system == "openbsd" || system == "netbsd")
+ else if (system == "freebsd" ||
+ system == "openbsd" ||
+ system == "netbsd")
class_ = "bsd";
- else if (system.compare (0, 5, "win32") == 0 || system == "mingw32")
+ else if (system.compare (0, 5, "win32") == 0 ||
+ system.compare (0, 7, "windows") == 0 ||
+ system == "mingw32")
class_ = "windows";
else
class_ = "other";