diff options
author | Chris Bieneman <beanz@apple.com> | 2016-04-29 22:28:34 +0000 |
---|---|---|
committer | Chris Bieneman <beanz@apple.com> | 2016-04-29 22:28:34 +0000 |
commit | 33d93d8f7c27cea70eca67af8dda79855208468e (patch) | |
tree | 1033d5e35ca61d7cea87007e5a69685b97390c94 /include/clang/Basic/DiagnosticDriverKinds.td | |
parent | fc79c367cf34d19184de9a7e163be9bb635c188a (diff) |
Add a new warning to notify users of mismatched SDK and deployment target
Summary:
This patch adds a new driver warning -Wincompatible-sdk which notifies the user when they are mismatching the version min options and the sysroot.
The patch works by checking the sysroot (if present) for an SDK name, then matching that against the target platform. In the case of a mismatch it logs a warning.
Reviewers: bob.wilson, rsmith
Subscribers: rsmith, edward-san, cfe-commits
Differential Revision: http://reviews.llvm.org/D18088
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@268127 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/DiagnosticDriverKinds.td')
-rw-r--r-- | include/clang/Basic/DiagnosticDriverKinds.td | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/clang/Basic/DiagnosticDriverKinds.td b/include/clang/Basic/DiagnosticDriverKinds.td index 2eab9b6428..e723e9dc1d 100644 --- a/include/clang/Basic/DiagnosticDriverKinds.td +++ b/include/clang/Basic/DiagnosticDriverKinds.td @@ -198,6 +198,8 @@ def warn_drv_pch_not_first_include : Warning< "precompiled header '%0' was ignored because '%1' is not first '-include'">; def warn_missing_sysroot : Warning<"no such sysroot directory: '%0'">, InGroup<DiagGroup<"missing-sysroot">>; +def warn_incompatible_sysroot : Warning<"using sysroot for '%0' but targeting '%1'">, + InGroup<DiagGroup<"incompatible-sysroot">>; def warn_debug_compression_unavailable : Warning<"cannot compress debug sections (zlib not installed)">, InGroup<DiagGroup<"debug-compression-unavailable">>; def warn_drv_enabling_rtti_with_exceptions : Warning< |