| 845 | } |
| 846 | |
| 847 | void cmComputeLinkDepends::FollowLinkEntry(BFSEntry qe) |
| 848 | { |
| 849 | // Get this entry representation. |
| 850 | size_t depender_index = qe.GroupIndex ? *qe.GroupIndex : qe.Index; |
| 851 | LinkEntry const& entry = this->EntryList[qe.Index]; |
| 852 | |
| 853 | // Follow the item's dependencies. |
| 854 | if (entry.Target) { |
| 855 | // Follow the target dependencies. |
| 856 | if (cmLinkInterface const* iface = |
| 857 | entry.Target->GetLinkInterface(this->Config, this->Target)) { |
| 858 | bool const isIface = |
| 859 | entry.Target->GetType() == cmStateEnums::INTERFACE_LIBRARY; |
| 860 | // This target provides its own link interface information. |
| 861 | this->AddLinkEntries(depender_index, iface->Libraries); |
| 862 | this->AddLinkObjects(iface->Objects); |
| 863 | for (auto const& language : iface->Languages) { |
| 864 | auto runtimeEntries = iface->LanguageRuntimeLibraries.find(language); |
| 865 | if (runtimeEntries != iface->LanguageRuntimeLibraries.end()) { |
| 866 | this->AddLinkEntries(depender_index, runtimeEntries->second); |
| 867 | } |
| 868 | } |
| 869 | |
| 870 | if (isIface) { |
| 871 | return; |
| 872 | } |
| 873 | |
| 874 | // Handle dependent shared libraries. |
| 875 | this->FollowSharedDeps(depender_index, iface); |
| 876 | } |
| 877 | } else { |
| 878 | // Follow the old-style dependency list. |
| 879 | this->AddVarLinkEntries(depender_index, qe.LibDepends); |
| 880 | } |
| 881 | } |
| 882 | |
| 883 | void cmComputeLinkDepends::FollowSharedDeps(size_t depender_index, |
| 884 | cmLinkInterface const* iface, |
no test coverage detected