summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorTarget.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-10-07 23:18:42 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-10-12 16:39:58 (GMT)
commitceb35b63a796235bb76284b3fb4046208365e23f (patch)
treef023761134dfe519e9faa11139b844d141c582bf /Source/cmGeneratorTarget.cxx
parentbf2d061ad37088be9ea6f135a980d14c4e76064b (diff)
downloadCMake-ceb35b63a796235bb76284b3fb4046208365e23f.zip
CMake-ceb35b63a796235bb76284b3fb4046208365e23f.tar.gz
CMake-ceb35b63a796235bb76284b3fb4046208365e23f.tar.bz2
cmLinkItem: Port to cmGeneratorTarget.
Diffstat (limited to 'Source/cmGeneratorTarget.cxx')
-rw-r--r--Source/cmGeneratorTarget.cxx20
1 files changed, 9 insertions, 11 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index d472c6c..f4ffd42 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -773,8 +773,10 @@ std::set<cmLinkItem> const& cmGeneratorTarget::GetUtilityItems() const
for(std::set<std::string>::const_iterator i = utilities.begin();
i != utilities.end(); ++i)
{
- this->UtilityItems.insert(
- cmLinkItem(*i, this->Makefile->FindTargetToUse(*i)));
+ cmTarget* tgt = this->Makefile->FindTargetToUse(*i);
+ cmGeneratorTarget* gt = tgt ? this->GlobalGenerator
+ ->GetGeneratorTarget(tgt) : 0;
+ this->UtilityItems.insert(cmLinkItem(*i, gt));
}
}
return this->UtilityItems;
@@ -1728,15 +1730,12 @@ public:
}
return;
}
- if(!this->Visited.insert(item.Target).second)
+ if(!this->Visited.insert(item.Target->Target).second)
{
return;
}
- cmGeneratorTarget* gtgt =
- this->Target->GetLocalGenerator()->GetGlobalGenerator()
- ->GetGeneratorTarget(item.Target);
cmLinkInterface const* iface =
- gtgt->GetLinkInterface(this->Config, this->HeadTarget);
+ item.Target->GetLinkInterface(this->Config, this->HeadTarget);
if(!iface) { return; }
for(std::vector<std::string>::const_iterator
@@ -2070,12 +2069,11 @@ void processILibs(const std::string& config,
std::vector<cmTarget const*>& tgts,
std::set<cmTarget const*>& emitted)
{
- if (item.Target && emitted.insert(item.Target).second)
+ if (item.Target && emitted.insert(item.Target->Target).second)
{
- tgts.push_back(item.Target);
- cmGeneratorTarget* gt = gg->GetGeneratorTarget(item.Target);
+ tgts.push_back(item.Target->Target);
if(cmLinkInterfaceLibraries const* iface =
- gt->GetLinkInterfaceLibraries(config, headTarget, true))
+ item.Target->GetLinkInterfaceLibraries(config, headTarget, true))
{
for(std::vector<cmLinkItem>::const_iterator
it = iface->Libraries.begin();