summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-02-20 15:43:00 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2017-02-20 15:43:00 (GMT)
commit168420f35cbcbd1ef0b2d24f3b254064e21c018e (patch)
tree218311d81394544429c3932fce579a3a5d1d0d0a /Source
parent53a1ec631ddd59f4f4eaaf1633a784045e455342 (diff)
parent3287ba02540ae94d6b0105f84e930aa19cf61b19 (diff)
downloadCMake-168420f35cbcbd1ef0b2d24f3b254064e21c018e.zip
CMake-168420f35cbcbd1ef0b2d24f3b254064e21c018e.tar.gz
CMake-168420f35cbcbd1ef0b2d24f3b254064e21c018e.tar.bz2
Merge topic 'fix-CMAKE_ROOT-case'
3287ba02 Make CMAKE_ROOT independent of case of path used to invoke cmake
Diffstat (limited to 'Source')
-rw-r--r--Source/cmSystemTools.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx
index 9efc13b..b3a7248 100644
--- a/Source/cmSystemTools.cxx
+++ b/Source/cmSystemTools.cxx
@@ -1978,6 +1978,7 @@ void cmSystemTools::FindCMakeResources(const char* argv0)
// ???
}
#endif
+ exe_dir = cmSystemTools::GetActualCaseForPath(exe_dir);
cmSystemToolsCMakeCommand = exe_dir;
cmSystemToolsCMakeCommand += "/cmake";
cmSystemToolsCMakeCommand += cmSystemTools::GetExecutableExtension();
@@ -2015,8 +2016,7 @@ void cmSystemTools::FindCMakeResources(const char* argv0)
// Install tree has
// - "<prefix><CMAKE_BIN_DIR>/cmake"
// - "<prefix><CMAKE_DATA_DIR>"
- const std::string actual_case = cmSystemTools::GetActualCaseForPath(exe_dir);
- if (cmHasSuffix(actual_case, CMAKE_BIN_DIR)) {
+ if (cmHasSuffix(exe_dir, CMAKE_BIN_DIR)) {
std::string const prefix =
exe_dir.substr(0, exe_dir.size() - strlen(CMAKE_BIN_DIR));
cmSystemToolsCMakeRoot = prefix + CMAKE_DATA_DIR;