summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGenerator.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-10-25 11:43:00 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-10-27 06:44:24 (GMT)
commita67231ac114235f0af4673235c4c07fa896c8ab6 (patch)
tree0c23756461e3a26b8a27fc3e340c928b1ca7f62a /Source/cmGlobalGenerator.cxx
parentd566f39a640297114bd3ad933bb3279440b2f38f (diff)
downloadCMake-a67231ac114235f0af4673235c4c07fa896c8ab6.zip
CMake-a67231ac114235f0af4673235c4c07fa896c8ab6.tar.gz
CMake-a67231ac114235f0af4673235c4c07fa896c8ab6.tar.bz2
cmTarget: Implement ALIAS in terms of name mapping
Remove mapping to cmTarget.
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))