mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-06 05:40:54 -06:00
cmake --build: Remove unnecessary source and build directory tracking
The save/restore from commit 427b6da9e5 (VS: Teach `cmake --build` to
reconfigure if needed before building, 2016-09-16, v3.8.0-rc1~290^2)
is unnecessary because `cmake::Build` does not rely on the source
and build directory being initialized.
This commit is contained in:
@@ -4020,8 +4020,6 @@ int cmake::Build(int jobs, std::string dir, std::vector<std::string> targets,
|
||||
if (!cmakeCheckStampList(stampList)) {
|
||||
// Correctly initialize the home (=source) and home output (=binary)
|
||||
// directories, which is required for running the generation step.
|
||||
std::string homeOrig = this->GetHomeDirectory();
|
||||
std::string homeOutputOrig = this->GetHomeOutputDirectory();
|
||||
this->SetDirectoriesFromFile(cachePath);
|
||||
|
||||
this->AddProjectCommands();
|
||||
@@ -4041,10 +4039,6 @@ int cmake::Build(int jobs, std::string dir, std::vector<std::string> targets,
|
||||
std::string message = cmStrCat("Build files have been written to: ",
|
||||
this->GetHomeOutputDirectory());
|
||||
this->UpdateProgress(message, -1);
|
||||
|
||||
// Restore the previously set directories to their original value.
|
||||
this->SetHomeDirectory(homeOrig);
|
||||
this->SetHomeOutputDirectory(homeOutputOrig);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user