[cfe-commits] r158926 - /cfe/trunk/lib/Driver/ToolChains.cpp

John McCall rjmccall at apple.com
Thu Jun 21 10:46:38 PDT 2012


Author: rjmccall
Date: Thu Jun 21 12:46:38 2012
New Revision: 158926

URL: http://llvm.org/viewvc/llvm-project?rev=158926&view=rev
Log:
Adjust this code so that it strictly honors
TargetSimulatroVersionFromDefines if present;  this also makes
it easier to chain things correctly.  Noted by an internal
review.

Modified:
    cfe/trunk/lib/Driver/ToolChains.cpp

Modified: cfe/trunk/lib/Driver/ToolChains.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains.cpp?rev=158926&r1=158925&r2=158926&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChains.cpp Thu Jun 21 12:46:38 2012
@@ -877,10 +877,12 @@
     StringRef where;
 
     // Complain about targetting iOS < 5.0 in any way.
-    if ((TargetSimulatorVersionFromDefines != VersionTuple() &&
-         TargetSimulatorVersionFromDefines < VersionTuple(5, 0)) ||
-        (isTargetIPhoneOS() && isIPhoneOSVersionLT(5, 0))) {
-      where = "iOS 5.0";
+    if (TargetSimulatorVersionFromDefines != VersionTuple()) {
+      if (TargetSimulatorVersionFromDefines < VersionTuple(5, 0))
+        where = "iOS 5.0";
+    } else if (isTargetIPhoneOS()) {
+      if (isIPhoneOSVersionLT(5, 0))
+        where = "iOS 5.0";
     }
 
     if (where != StringRef()) {





More information about the cfe-commits mailing list