]> granicus.if.org Git - clang/commitdiff
[Basic] Transition getEnvironmentVersion from getOSVersion for android
authorDavid Majnemer <david.majnemer@gmail.com>
Mon, 1 Jun 2015 23:38:25 +0000 (23:38 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Mon, 1 Jun 2015 23:38:25 +0000 (23:38 +0000)
'android' occupies the environment component of the triple.  Let's use
getEnvironmentVersion to extract it instead of getOSVersion.

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

lib/Basic/Targets.cpp

index 0eb5cee351bd065d5cb631c591558b7a2f450ec2..f70d588ec0cef5d8cbcfe73ce1e91272d59db71c 100644 (file)
@@ -389,7 +389,7 @@ protected:
     if (Triple.getEnvironment() == llvm::Triple::Android) {
       Builder.defineMacro("__ANDROID__", "1");
       unsigned Maj, Min, Rev;
-      Triple.getOSVersion(Maj, Min, Rev);
+      Triple.getEnvironmentVersion(Maj, Min, Rev);
       this->PlatformName = "android";
       this->PlatformMinVersion = VersionTuple(Maj, Min, Rev);
     }