summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-03-14 14:38:19 (GMT)
committerBrad King <brad.king@kitware.com>2016-03-16 13:03:26 (GMT)
commit3144857e1eed83e038699942568869bfce461d4d (patch)
tree308a88383bed0e65d0bae865ed84e8d1fdd5f092 /Source/cmGlobalGenerator.cxx
parenta87253154e15da3f05ec7a4c625caaa0c54a3861 (diff)
downloadCMake-3144857e1eed83e038699942568869bfce461d4d.zip
CMake-3144857e1eed83e038699942568869bfce461d4d.tar.gz
CMake-3144857e1eed83e038699942568869bfce461d4d.tar.bz2
Avoid depending on CMAKE_ROOT cache entry internally (#16015)
Use cmSystemTools::GetCMakeRoot() which always knows the location of our resources. Do not depend on CMAKE_ROOT because the user could unset it from the cache.
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r--Source/cmGlobalGenerator.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index c628406..1d0ade4 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -820,7 +820,7 @@ cmGlobalGenerator::EnableLanguage(std::vector<std::string>const& languages,
// Now load files that can override any settings on the platform or for
// the project First load the project compatibility file if it is in
// cmake
- std::string projectCompatibility = mf->GetDefinition("CMAKE_ROOT");
+ std::string projectCompatibility = cmSystemTools::GetCMakeRoot();
projectCompatibility += "/Modules/";
projectCompatibility += mf->GetSafeDefinition("PROJECT_NAME");
projectCompatibility += "Compatibility.cmake";