summaryrefslogtreecommitdiffstats
path: root/Source/cmake.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r--Source/cmake.cxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 2aa092a..fececfd 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -377,11 +377,11 @@ void cmake::ReadListFile(const std::vector<std::string>& args,
this->SetHomeDirectory(cmSystemTools::GetCurrentWorkingDirectory());
this->SetHomeOutputDirectory(cmSystemTools::GetCurrentWorkingDirectory());
cmState::Snapshot snapshot = this->GetCurrentSnapshot();
- cmsys::auto_ptr<cmMakefile> mf(new cmMakefile(gg, snapshot));
- mf->SetCurrentBinaryDirectory
+ snapshot.GetDirectory().SetCurrentBinary
(cmSystemTools::GetCurrentWorkingDirectory());
- mf->SetCurrentSourceDirectory
+ snapshot.GetDirectory().SetCurrentSource
(cmSystemTools::GetCurrentWorkingDirectory());
+ cmsys::auto_ptr<cmMakefile> mf(new cmMakefile(gg, snapshot));
if (this->GetWorkingMode() != NORMAL_MODE)
{
std::string file(cmSystemTools::CollapseFullPath(path));
@@ -418,13 +418,13 @@ bool cmake::FindPackage(const std::vector<std::string>& args)
this->SetGlobalGenerator(gg);
cmState::Snapshot snapshot = this->GetCurrentSnapshot();
+ snapshot.GetDirectory().SetCurrentBinary
+ (cmSystemTools::GetCurrentWorkingDirectory());
+ snapshot.GetDirectory().SetCurrentSource
+ (cmSystemTools::GetCurrentWorkingDirectory());
// read in the list file to fill the cache
cmsys::auto_ptr<cmMakefile> mf(new cmMakefile(gg, snapshot));
cmsys::auto_ptr<cmLocalGenerator> lg(gg->CreateLocalGenerator(mf.get()));
- mf->SetCurrentBinaryDirectory
- (cmSystemTools::GetCurrentWorkingDirectory());
- mf->SetCurrentSourceDirectory
- (cmSystemTools::GetCurrentWorkingDirectory());
mf->SetArgcArgv(args);