summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-10-05 18:52:26 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-10-05 18:52:26 (GMT)
commit0a73044579a687d1f610a3b6d65e801d2f217435 (patch)
treefb82621cb83b0f65719c98231d36e6fcf2a760d0
parent3339a7508e2d90cbc832490e64f593c1ab935097 (diff)
downloadCMake-0a73044579a687d1f610a3b6d65e801d2f217435.zip
CMake-0a73044579a687d1f610a3b6d65e801d2f217435.tar.gz
CMake-0a73044579a687d1f610a3b6d65e801d2f217435.tar.bz2
cmake: Remove needless cmLocalGenerator creation.
-rw-r--r--Source/cmake.cxx12
1 files changed, 5 insertions, 7 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 386f6a5..2aa092a 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -378,20 +378,19 @@ void cmake::ReadListFile(const std::vector<std::string>& args,
this->SetHomeOutputDirectory(cmSystemTools::GetCurrentWorkingDirectory());
cmState::Snapshot snapshot = this->GetCurrentSnapshot();
cmsys::auto_ptr<cmMakefile> mf(new cmMakefile(gg, snapshot));
- cmsys::auto_ptr<cmLocalGenerator> lg(gg->CreateLocalGenerator(mf.get()));
- lg->GetMakefile()->SetCurrentBinaryDirectory
+ mf->SetCurrentBinaryDirectory
(cmSystemTools::GetCurrentWorkingDirectory());
- lg->GetMakefile()->SetCurrentSourceDirectory
+ mf->SetCurrentSourceDirectory
(cmSystemTools::GetCurrentWorkingDirectory());
if (this->GetWorkingMode() != NORMAL_MODE)
{
std::string file(cmSystemTools::CollapseFullPath(path));
cmSystemTools::ConvertToUnixSlashes(file);
- lg->GetMakefile()->SetScriptModeFile(file.c_str());
+ mf->SetScriptModeFile(file.c_str());
- lg->GetMakefile()->SetArgcArgv(args);
+ mf->SetArgcArgv(args);
}
- if (!lg->GetMakefile()->ReadListFile(path))
+ if (!mf->ReadListFile(path))
{
cmSystemTools::Error("Error processing file: ", path);
}
@@ -1906,7 +1905,6 @@ int cmake::CheckBuildSystem()
cm.SetHomeOutputDirectory("");
cmGlobalGenerator gg(&cm);
cmsys::auto_ptr<cmMakefile> mf(new cmMakefile(&gg, cm.GetCurrentSnapshot()));
- cmsys::auto_ptr<cmLocalGenerator> lg(gg.CreateLocalGenerator(mf.get()));
if(!mf->ReadListFile(this->CheckBuildSystemArgument.c_str()) ||
cmSystemTools::GetErrorOccuredFlag())
{