summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2022-01-12 14:57:15 (GMT)
committerKitware Robot <kwrobot@kitware.com>2022-01-12 14:57:23 (GMT)
commit0c038689be424ca71a6699a993adde3bcaa15b6c (patch)
treeb638a68a4238c8616d5d80c5d4d11a8a19378003 /Source
parenta97cc1ca2de8a7720e5352ad587344669435ae5c (diff)
parentec1e40af1adda4e884168a7972c24e2d8ff33438 (diff)
downloadCMake-0c038689be424ca71a6699a993adde3bcaa15b6c.zip
CMake-0c038689be424ca71a6699a993adde3bcaa15b6c.tar.gz
CMake-0c038689be424ca71a6699a993adde3bcaa15b6c.tar.bz2
Merge topic 'better_error_message_on_unsupported_language_level'
ec1e40af1a cmStandardLevelResolver: Better error message on unsupported language level Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6854
Diffstat (limited to 'Source')
-rw-r--r--Source/cmStandardLevelResolver.cxx8
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/cmStandardLevelResolver.cxx b/Source/cmStandardLevelResolver.cxx
index 61416e0..c027e29 100644
--- a/Source/cmStandardLevelResolver.cxx
+++ b/Source/cmStandardLevelResolver.cxx
@@ -152,8 +152,12 @@ struct StandardLevelComputer
"dialect \""
<< this->Language << *standardProp << "\" "
<< (ext ? "(with compiler extensions)" : "")
- << ", but CMake "
- "does not know the compile flags to use to enable it.";
+ << ". But the current compiler \""
+ << makefile->GetSafeDefinition("CMAKE_" + this->Language +
+ "_COMPILER_ID")
+ << "\" does not support this, or "
+ "CMake does not know the flags to enable it.";
+
makefile->IssueMessage(MessageType::FATAL_ERROR, e.str());
}
return option_flag;