diff options
author | Brad King <brad.king@kitware.com> | 2015-09-18 12:47:27 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-09-18 14:01:25 (GMT) |
commit | 828c05b9f567e0652ebbee6df2799a189ff586fe (patch) | |
tree | 94c0e1f15447d5edf18404855349ee4b565f976a /Source/cmSystemTools.cxx | |
parent | c73fbda66b5985e4ba99499f871ffd19bcf32aaa (diff) | |
download | CMake-828c05b9f567e0652ebbee6df2799a189ff586fe.zip CMake-828c05b9f567e0652ebbee6df2799a189ff586fe.tar.gz CMake-828c05b9f567e0652ebbee6df2799a189ff586fe.tar.bz2 |
Ninja: Refactor lookup of cmcldeps location
This executable comes with CMake so just compute its location in
cmSystemTools instead of storing it in compiler information modules.
Diffstat (limited to 'Source/cmSystemTools.cxx')
-rw-r--r-- | Source/cmSystemTools.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index 005a803..2675066 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -2216,6 +2216,7 @@ static std::string cmSystemToolsCTestCommand; static std::string cmSystemToolsCPackCommand; static std::string cmSystemToolsCMakeCursesCommand; static std::string cmSystemToolsCMakeGUICommand; +static std::string cmSystemToolsCMClDepsCommand; static std::string cmSystemToolsCMakeRoot; void cmSystemTools::FindCMakeResources(const char* argv0) { @@ -2308,6 +2309,13 @@ void cmSystemTools::FindCMakeResources(const char* argv0) { cmSystemToolsCMakeCursesCommand = ""; } + cmSystemToolsCMClDepsCommand = exe_dir; + cmSystemToolsCMClDepsCommand += "/cmcldeps"; + cmSystemToolsCMClDepsCommand += cmSystemTools::GetExecutableExtension(); + if(!cmSystemTools::FileExists(cmSystemToolsCMClDepsCommand.c_str())) + { + cmSystemToolsCMClDepsCommand = ""; + } #ifdef CMAKE_BUILD_WITH_CMAKE // Install tree has "<prefix>/bin/cmake" and "<prefix><CMAKE_DATA_DIR>". @@ -2375,6 +2383,12 @@ std::string const& cmSystemTools::GetCMakeGUICommand() } //---------------------------------------------------------------------------- +std::string const& cmSystemTools::GetCMClDepsCommand() +{ + return cmSystemToolsCMClDepsCommand; +} + +//---------------------------------------------------------------------------- std::string const& cmSystemTools::GetCMakeRoot() { return cmSystemToolsCMakeRoot; |