summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r--Source/cmGlobalGenerator.cxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index 215d63f..47d254e 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -2167,9 +2167,10 @@ cmGlobalGenerator::FindLocalGenerator(const std::string& start_dir) const
}
//----------------------------------------------------------------------------
-void cmGlobalGenerator::AddAlias(const std::string& name, cmTarget *tgt)
+void cmGlobalGenerator::AddAlias(const std::string& name,
+ std::string const& tgtName)
{
- this->AliasTargets[name] = tgt;
+ this->AliasTargets[name] = tgtName;
}
//----------------------------------------------------------------------------
@@ -2220,10 +2221,11 @@ cmGlobalGenerator::FindTarget(const std::string& name,
{
if (!excludeAliases)
{
- TargetMap::const_iterator ai = this->AliasTargets.find(name);
+ std::map<std::string, std::string>::const_iterator ai =
+ this->AliasTargets.find(name);
if (ai != this->AliasTargets.end())
{
- return ai->second;
+ return this->FindTargetImpl(ai->second);
}
}
if (cmTarget* tgt = this->FindTargetImpl(name))