diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2002-12-05 21:53:09 (GMT) |
---|---|---|
committer | Bill Hoffman <bill.hoffman@kitware.com> | 2002-12-05 21:53:09 (GMT) |
commit | 19aa18fd2622ae22934a4a831c6de3b6af20f151 (patch) | |
tree | 0c39388606215cae776d693004fdcf4d33a6b21b /Source | |
parent | a551bfcafc6137e5e592d1af26847625e66c75e8 (diff) | |
download | CMake-19aa18fd2622ae22934a4a831c6de3b6af20f151.zip CMake-19aa18fd2622ae22934a4a831c6de3b6af20f151.tar.gz CMake-19aa18fd2622ae22934a4a831c6de3b6af20f151.tar.bz2 |
use correct path type for check_cache file
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator.cxx | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator.cxx b/Source/cmLocalUnixMakefileGenerator.cxx index 875da65..8f5cb68 100644 --- a/Source/cmLocalUnixMakefileGenerator.cxx +++ b/Source/cmLocalUnixMakefileGenerator.cxx @@ -215,13 +215,15 @@ void cmLocalUnixMakefileGenerator::OutputMakefile(const char* file, fout << " " << cmSystemTools::ConvertToOutputPath(cacheFile.c_str()); fout << "\n\n\n"; this->OutputMakeVariables(fout); - + std::string checkCache = m_Makefile->GetHomeOutputDirectory(); + checkCache += "/cmake.check_cache"; + checkCache = cmSystemTools::ConvertToOutputPath(checkCache.c_str()); // Set up the default target as the VERY first target, so that make with no arguments will run it this-> OutputMakeRule(fout, "Default target executed when no arguments are given to make, first make sure cmake.depends exists, cmake.check_depends is up-to-date, check the sources, then build the all target", "default_target", - "$(CMAKE_BINARY_DIR)/cmake.check_cache", + checkCache.c_str(), "$(MAKE) $(MAKESILENT) cmake.depends", "$(MAKE) $(MAKESILENT) cmake.check_depends", "$(MAKE) $(MAKESILENT) -f cmake.check_depends", @@ -2121,11 +2123,19 @@ void cmLocalUnixMakefileGenerator::OutputMakeRules(std::ostream& fout) "rebuild_cache", "$(CMAKE_BINARY_DIR)/CMakeCache.txt", "$(CMAKE_COMMAND) " - "-H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)"); + "-H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)"); + std::string checkCache = m_Makefile->GetHomeOutputDirectory(); + checkCache += "/cmake.check_cache"; + checkCache = cmSystemTools::ConvertToOutputPath(checkCache.c_str()); + + std::string CMakeCache = m_Makefile->GetHomeOutputDirectory(); + CMakeCache += "/CMakeCache.txt"; + CMakeCache = cmSystemTools::ConvertToOutputPath(CMakeCache.c_str()); + this->OutputMakeRule(fout, "CMakeCache.txt because out-of-date:", - "$(CMAKE_BINARY_DIR)/cmake.check_cache", - "$(CMAKE_BINARY_DIR)/CMakeCache.txt", + checkCache.c_str(), + CMakeCache.c_str(), "$(CMAKE_COMMAND) " "-H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)"); // if CMAKE_EDIT_COMMAND is defined then add a rule to run it |