diff options
Diffstat (limited to 'Source/cmComputeTargetDepends.cxx')
-rw-r--r-- | Source/cmComputeTargetDepends.cxx | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/Source/cmComputeTargetDepends.cxx b/Source/cmComputeTargetDepends.cxx index 6196542..3929af4 100644 --- a/Source/cmComputeTargetDepends.cxx +++ b/Source/cmComputeTargetDepends.cxx @@ -249,13 +249,15 @@ void cmComputeTargetDepends::CollectTargetDepends(int depender_index) const_cast<cmTarget*>(depender)->AddUtility(objLib); } } - std::vector<std::string> tlibs; - depender->GetDirectLinkLibraries(*it, tlibs); + + cmTarget::LinkImplementation const* impl = + depender->GetLinkImplementation(*it); // A target should not depend on itself. emitted.insert(depender->GetName()); - for(std::vector<std::string>::const_iterator lib = tlibs.begin(); - lib != tlibs.end(); ++lib) + for(std::vector<cmLinkItem>::const_iterator + lib = impl->Libraries.begin(); + lib != impl->Libraries.end(); ++lib) { // Don't emit the same library twice for this target. if(emitted.insert(*lib).second) @@ -269,11 +271,11 @@ void cmComputeTargetDepends::CollectTargetDepends(int depender_index) // Loop over all utility dependencies. { - std::set<std::string> const& tutils = depender->GetUtilities(); + std::set<cmLinkItem> const& tutils = depender->GetUtilityItems(); std::set<std::string> emitted; // A target should not depend on itself. emitted.insert(depender->GetName()); - for(std::set<std::string>::const_iterator util = tutils.begin(); + for(std::set<cmLinkItem>::const_iterator util = tutils.begin(); util != tutils.end(); ++util) { // Don't emit the same utility twice for this target. @@ -295,7 +297,7 @@ void cmComputeTargetDepends::AddInterfaceDepends(int depender_index, if(cmTarget::LinkInterface const* iface = dependee->GetLinkInterface(config, depender)) { - for(std::vector<std::string>::const_iterator + for(std::vector<cmLinkItem>::const_iterator lib = iface->Libraries.begin(); lib != iface->Libraries.end(); ++lib) { @@ -311,12 +313,11 @@ void cmComputeTargetDepends::AddInterfaceDepends(int depender_index, //---------------------------------------------------------------------------- void cmComputeTargetDepends::AddInterfaceDepends(int depender_index, - const std::string& dependee_name, + cmLinkItem const& dependee_name, std::set<std::string> &emitted) { cmTarget const* depender = this->Targets[depender_index]; - cmTarget const* dependee = - depender->GetMakefile()->FindTargetToUse(dependee_name); + cmTarget const* dependee = dependee_name.Target; // Skip targets that will not really be linked. This is probably a // name conflict between an external library and an executable // within the project. @@ -344,16 +345,15 @@ void cmComputeTargetDepends::AddInterfaceDepends(int depender_index, } //---------------------------------------------------------------------------- -void cmComputeTargetDepends::AddTargetDepend(int depender_index, - const std::string& dependee_name, - bool linking) +void cmComputeTargetDepends::AddTargetDepend( + int depender_index, cmLinkItem const& dependee_name, + bool linking) { // Get the depender. cmTarget const* depender = this->Targets[depender_index]; // Check the target's makefile first. - cmTarget const* dependee = - depender->GetMakefile()->FindTargetToUse(dependee_name); + cmTarget const* dependee = dependee_name.Target; if(!dependee && !linking && (depender->GetType() != cmTarget::GLOBAL_TARGET)) |