diff options
| author | John McCall <rjmccall@apple.com> | 2012-06-21 17:46:38 +0000 |
|---|---|---|
| committer | John McCall <rjmccall@apple.com> | 2012-06-21 17:46:38 +0000 |
| commit | f60e437168c8c4aff4b404b4bb6acf57b7f95cdd (patch) | |
| tree | 906e4b518058b2a57c951c36e22acdc4aa523f92 | |
| parent | b2fd5f66b48f3b125537a78065cf2409f87d5d87 (diff) | |
| download | bcm5719-llvm-f60e437168c8c4aff4b404b4bb6acf57b7f95cdd.tar.gz bcm5719-llvm-f60e437168c8c4aff4b404b4bb6acf57b7f95cdd.zip | |
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.
llvm-svn: 158926
| -rw-r--r-- | clang/lib/Driver/ToolChains.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/clang/lib/Driver/ToolChains.cpp b/clang/lib/Driver/ToolChains.cpp index 1a0cd939ddc..93df747c3f1 100644 --- a/clang/lib/Driver/ToolChains.cpp +++ b/clang/lib/Driver/ToolChains.cpp @@ -877,10 +877,12 @@ DerivedArgList *Darwin::TranslateArgs(const DerivedArgList &Args, 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()) { |

