diff options
author | Brad King <brad.king@kitware.com> | 2015-04-21 13:42:07 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2015-04-21 13:42:07 (GMT) |
commit | 5a5ef00106662da5c6400d76438289f505b4a1ff (patch) | |
tree | fc3dcb6d19a8d1d9bc28a1f60338551c3a4e510c /Source/cmGlobalGenerator.cxx | |
parent | 81c01d4a3461cf645ff3db794cf6217318f268d3 (diff) | |
parent | 8dc3a67c9c3c5b49fe7a3b69dab7d60475414c59 (diff) | |
download | CMake-5a5ef00106662da5c6400d76438289f505b4a1ff.zip CMake-5a5ef00106662da5c6400d76438289f505b4a1ff.tar.gz CMake-5a5ef00106662da5c6400d76438289f505b4a1ff.tar.bz2 |
Merge topic 'clean-up-cmMakefile'
8dc3a67c cmMakefile: Out-of-line the directory methods.
0f3c8cfa cmMakefile: Use method abstraction to access directories.
b288a997 cmMakefile: Rename SetStart* directory API to SetCurrent*.
932d53bc cmMakefile: Remove redundant method duplication.
32b8f03a cmMakefile: Port users of GetStart* methods to new names.
54d6a918 cmMakefile: Rename GetCurrent{Output,Binary}Directory.
55d80d0a cmMakefile: Rename GetCurrent{,Source}Directory.
b23cf06f cmake: Remove redundant start directories.
fcf246ac cmMakefile: Populate Home directories on initialize.
8878bea7 cmake: Initialize Home directories on cmake for find-package mode.
044dc815 Use the Home directories from the cmake class where intended.
d67e8f24 cmake: Fix directory used to find the cache
1ea085d1 cmMakefile: Initialize dir definitions early.
f034bb2f Remove redundant calls to MakeStartDirectoriesCurrent.
3a68c323 cmMakefile: Fix wrong parameter names.
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r-- | Source/cmGlobalGenerator.cxx | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index 4b0ef58..774b172 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -1098,14 +1098,13 @@ void cmGlobalGenerator::Configure() this->LocalGenerators.push_back(lg); // set the Start directories - cmMakefile* mf = lg->GetMakefile(); - lg->GetMakefile()->SetStartDirectory - (this->CMakeInstance->GetStartDirectory()); - lg->GetMakefile()->SetStartOutputDirectory - (this->CMakeInstance->GetStartOutputDirectory()); - lg->GetMakefile()->MakeStartDirectoriesCurrent(); + lg->GetMakefile()->SetCurrentSourceDirectory + (this->CMakeInstance->GetHomeDirectory()); + lg->GetMakefile()->SetCurrentBinaryDirectory + (this->CMakeInstance->GetHomeOutputDirectory()); - this->BinaryDirectories.insert(mf->GetStartOutputDirectory()); + this->BinaryDirectories.insert( + this->CMakeInstance->GetHomeOutputDirectory()); // now do it lg->Configure(); @@ -1568,7 +1567,8 @@ void cmGlobalGenerator::CheckLocalGenerators() text += "\n linked by target \""; text += l->second.GetName(); text += "\" in directory "; - text+=this->LocalGenerators[i]->GetMakefile()->GetCurrentDirectory(); + text+=this->LocalGenerators[i]->GetMakefile() + ->GetCurrentSourceDirectory(); notFoundMap[varName] = text; } } @@ -1598,7 +1598,7 @@ void cmGlobalGenerator::CheckLocalGenerators() std::string text = notFoundMap[varName]; text += "\n used as include directory in directory "; text += this->LocalGenerators[i] - ->GetMakefile()->GetCurrentDirectory(); + ->GetMakefile()->GetCurrentSourceDirectory(); notFoundMap[varName] = text; } } @@ -2046,7 +2046,7 @@ cmGlobalGenerator::FindLocalGenerator(const std::string& start_dir) const for(std::vector<cmLocalGenerator*>::const_iterator it = this->LocalGenerators.begin(); it != this->LocalGenerators.end(); ++it) { - std::string sd = (*it)->GetMakefile()->GetStartDirectory(); + std::string sd = (*it)->GetMakefile()->GetCurrentSourceDirectory(); if (sd == start_dir) { return *it; @@ -2136,7 +2136,7 @@ void cmGlobalGenerator::CreateDefaultGlobalTargets(cmTargets* targets) const char* cmakeCommand = mf->GetRequiredDefinition("CMAKE_COMMAND"); // CPack - std::string workingDir = mf->GetStartOutputDirectory(); + std::string workingDir = mf->GetCurrentBinaryDirectory(); cmCustomCommandLines cpackCommandLines; std::vector<std::string> depends; cmCustomCommandLine singleLine; @@ -2147,7 +2147,7 @@ void cmGlobalGenerator::CreateDefaultGlobalTargets(cmTargets* targets) singleLine.push_back(cmakeCfgIntDir); } singleLine.push_back("--config"); - std::string configFile = mf->GetStartOutputDirectory();; + std::string configFile = mf->GetCurrentBinaryDirectory();; configFile += "/CPackConfig.cmake"; std::string relConfigFile = "./CPackConfig.cmake"; singleLine.push_back(relConfigFile); @@ -2183,7 +2183,7 @@ void cmGlobalGenerator::CreateDefaultGlobalTargets(cmTargets* targets) depends.erase(depends.begin(), depends.end()); singleLine.push_back(cmSystemTools::GetCPackCommand()); singleLine.push_back("--config"); - configFile = mf->GetStartOutputDirectory();; + configFile = mf->GetCurrentBinaryDirectory();; configFile += "/CPackSourceConfig.cmake"; relConfigFile = "./CPackSourceConfig.cmake"; singleLine.push_back(relConfigFile); @@ -3070,7 +3070,7 @@ bool cmGlobalGenerator::GenerateCPackPropertiesFile() std::vector<std::string> configs; std::string config = mf->GetConfigurations(configs, false); - std::string path = this->CMakeInstance->GetStartOutputDirectory(); + std::string path = this->CMakeInstance->GetHomeOutputDirectory(); path += "/CPackProperties.cmake"; if(!cmSystemTools::FileExists(path.c_str()) && installedFiles.empty()) |