diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-06-06 13:14:04 +0200 |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-06-22 13:23:45 -0400 |
commit | a3b210fd6cb85cba76f867e93d94dd835fa3278a (patch) | |
tree | 82de7537dc09b00543d680bf24e53b01a7d362f7 /Source | |
parent | 8ec60c675a3fb4294776b2d644974361b145c444 (diff) | |
download | cmake-a3b210fd6cb85cba76f867e93d94dd835fa3278a.tar.gz |
cmGeneratorTarget: Require a cmLocalGenerator to construct.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmGeneratorTarget.cxx | 5 | ||||
-rw-r--r-- | Source/cmGeneratorTarget.h | 2 | ||||
-rw-r--r-- | Source/cmGlobalGenerator.cxx | 4 |
3 files changed, 6 insertions, 5 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index 482eefddc4..4494553062 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -220,11 +220,12 @@ struct TagVisitor }; //---------------------------------------------------------------------------- -cmGeneratorTarget::cmGeneratorTarget(cmTarget* t): Target(t), +cmGeneratorTarget::cmGeneratorTarget(cmTarget* t, cmLocalGenerator* lg) + : Target(t), SourceFileFlagsConstructed(false) { this->Makefile = this->Target->GetMakefile(); - this->LocalGenerator = this->Makefile->GetLocalGenerator(); + this->LocalGenerator = lg; this->GlobalGenerator = this->Makefile->GetGlobalGenerator(); } diff --git a/Source/cmGeneratorTarget.h b/Source/cmGeneratorTarget.h index 645b79284d..675ee9ffad 100644 --- a/Source/cmGeneratorTarget.h +++ b/Source/cmGeneratorTarget.h @@ -24,7 +24,7 @@ class cmTarget; class cmGeneratorTarget { public: - cmGeneratorTarget(cmTarget*); + cmGeneratorTarget(cmTarget*, cmLocalGenerator* lg); cmLocalGenerator* GetLocalGenerator() const; diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index c4396c628d..14eaeac7a1 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -1465,7 +1465,7 @@ void cmGlobalGenerator::CreateGeneratorTargets(cmLocalGenerator *lg) ti != targets.end(); ++ti) { cmTarget* t = &ti->second; - cmGeneratorTarget* gt = new cmGeneratorTarget(t); + cmGeneratorTarget* gt = new cmGeneratorTarget(t, lg); this->ComputeTargetObjectDirectory(gt); this->GeneratorTargets[t] = gt; generatorTargets[t] = gt; @@ -1475,7 +1475,7 @@ void cmGlobalGenerator::CreateGeneratorTargets(cmLocalGenerator *lg) j = mf->GetOwnedImportedTargets().begin(); j != mf->GetOwnedImportedTargets().end(); ++j) { - cmGeneratorTarget* gt = new cmGeneratorTarget(*j); + cmGeneratorTarget* gt = new cmGeneratorTarget(*j, lg); this->GeneratorTargets[*j] = gt; generatorTargets[*j] = gt; } |