diff options
author | Brad King <brad.king@kitware.com> | 2008-03-24 14:56:26 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2008-03-24 14:56:26 (GMT) |
commit | 1655dce2a58c6629ae4455d369c34a8b40924b22 (patch) | |
tree | 1e1d5af8c0b94609667570e4f96cb17ed67d570f /Source/cmCMakeMinimumRequired.cxx | |
parent | a24ff4e453701b927959555ce7dab895870e6ae8 (diff) | |
download | CMake-1655dce2a58c6629ae4455d369c34a8b40924b22.zip CMake-1655dce2a58c6629ae4455d369c34a8b40924b22.tar.gz CMake-1655dce2a58c6629ae4455d369c34a8b40924b22.tar.bz2 |
ENH: Cleanup policy version interface presented to user.
- In cmake_minimum_required do not set policy version if current
CMake is too old
- In cmPolicies::ApplyPolicyVersion report error if version is too
new or cannot be parsed
Diffstat (limited to 'Source/cmCMakeMinimumRequired.cxx')
-rw-r--r-- | Source/cmCMakeMinimumRequired.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/Source/cmCMakeMinimumRequired.cxx b/Source/cmCMakeMinimumRequired.cxx index bb5bdb0..f04600e 100644 --- a/Source/cmCMakeMinimumRequired.cxx +++ b/Source/cmCMakeMinimumRequired.cxx @@ -99,13 +99,12 @@ bool cmCMakeMinimumRequired { // The current version is too low. cmOStringStream e; - e << "This project requires version " << version_string.c_str() - << " of CMake. " - << "You are running version " - << current_major << "." << current_minor << "." << current_patch - << ".\n"; - cmSystemTools::Error(e.str().c_str()); + e << "CMake " << version_string.c_str() + << " or higher is required. You are running version " + << current_major << "." << current_minor << "." << current_patch; + this->Makefile->IssueMessage(cmake::FATAL_ERROR, e.str()); cmSystemTools::SetFatalErrorOccured(); + return true; } if (required_major < 2 || required_major == 2 && required_minor < 4) |