summaryrefslogtreecommitdiffstats
path: root/Source/cmCMakeMinimumRequired.cxx
diff options
context:
space:
mode:
authorKen Martin <ken.martin@kitware.com>2008-03-07 16:43:47 (GMT)
committerKen Martin <ken.martin@kitware.com>2008-03-07 16:43:47 (GMT)
commit55eede4b131e39cc341832cd99d3b339f040af75 (patch)
tree7a36fdcf05163e4a35e2c0ecc3b91d017afe7236 /Source/cmCMakeMinimumRequired.cxx
parent497779d4b3be8ac387690bc95fdadab122fa5a3c (diff)
downloadCMake-55eede4b131e39cc341832cd99d3b339f040af75.zip
CMake-55eede4b131e39cc341832cd99d3b339f040af75.tar.gz
CMake-55eede4b131e39cc341832cd99d3b339f040af75.tar.bz2
ENH: clean up some policy stuff and interactions with CMAKE_BACKWARDS_COMPATIBILITY and CMAKE_MINIMUM_REQUIRED
Diffstat (limited to 'Source/cmCMakeMinimumRequired.cxx')
-rw-r--r--Source/cmCMakeMinimumRequired.cxx9
1 files changed, 9 insertions, 0 deletions
diff --git a/Source/cmCMakeMinimumRequired.cxx b/Source/cmCMakeMinimumRequired.cxx
index 54acb89..bb5bdb0 100644
--- a/Source/cmCMakeMinimumRequired.cxx
+++ b/Source/cmCMakeMinimumRequired.cxx
@@ -108,6 +108,15 @@ bool cmCMakeMinimumRequired
cmSystemTools::SetFatalErrorOccured();
}
+ if (required_major < 2 || required_major == 2 && required_minor < 4)
+ {
+ this->Makefile->SetPolicyVersion("2.4");
+ }
+ else
+ {
+ this->Makefile->SetPolicyVersion(version_string.c_str());
+ }
+
return true;
}