diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-08-26 17:38:14 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-08-26 17:38:14 (GMT) |
commit | 84b847e42fde288bc102198aedeb68e19b41ef1e (patch) | |
tree | 16d9e6e81add439e4ee1065db57b9c6b48df62d2 /Source/cmTarget.cxx | |
parent | 6220241fd0bb7902c932742a7aa3d6a96fd0e919 (diff) | |
download | CMake-84b847e42fde288bc102198aedeb68e19b41ef1e.zip CMake-84b847e42fde288bc102198aedeb68e19b41ef1e.tar.gz CMake-84b847e42fde288bc102198aedeb68e19b41ef1e.tar.bz2 |
cmGeneratorTarget: Move ComputeLinkInterface from cmTarget.
Diffstat (limited to 'Source/cmTarget.cxx')
-rw-r--r-- | Source/cmTarget.cxx | 97 |
1 files changed, 0 insertions, 97 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index ee298ac..c8a9148 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -4358,103 +4358,6 @@ cmTarget::ComputeLinkInterfaceLibraries( } } -//---------------------------------------------------------------------------- -void cmTarget::ComputeLinkInterface(const std::string& config, - cmOptionalLinkInterface &iface, - cmTarget const* headTarget) const -{ - if(iface.ExplicitLibraries) - { - if(this->GetType() == cmTarget::SHARED_LIBRARY - || this->GetType() == cmTarget::STATIC_LIBRARY - || this->GetType() == cmTarget::INTERFACE_LIBRARY) - { - // Shared libraries may have runtime implementation dependencies - // on other shared libraries that are not in the interface. - UNORDERED_SET<std::string> emitted; - for(std::vector<cmLinkItem>::const_iterator - li = iface.Libraries.begin(); li != iface.Libraries.end(); ++li) - { - emitted.insert(*li); - } - if (this->GetType() != cmTarget::INTERFACE_LIBRARY) - { - cmTarget::LinkImplementation const* impl = - this->GetLinkImplementation(config); - for(std::vector<cmLinkImplItem>::const_iterator - li = impl->Libraries.begin(); li != impl->Libraries.end(); ++li) - { - if(emitted.insert(*li).second) - { - if(li->Target) - { - // This is a runtime dependency on another shared library. - if(li->Target->GetType() == cmTarget::SHARED_LIBRARY) - { - iface.SharedDeps.push_back(*li); - } - } - else - { - // TODO: Recognize shared library file names. Perhaps this - // should be moved to cmComputeLinkInformation, but that creates - // a chicken-and-egg problem since this list is needed for its - // construction. - } - } - } - } - } - } - else if (this->GetPolicyStatusCMP0022() == cmPolicies::WARN - || this->GetPolicyStatusCMP0022() == cmPolicies::OLD) - { - // The link implementation is the default link interface. - cmLinkImplementationLibraries const* - impl = this->GetLinkImplementationLibrariesInternal(config, - headTarget); - iface.ImplementationIsInterface = true; - iface.WrongConfigLibraries = impl->WrongConfigLibraries; - } - - if(this->LinkLanguagePropagatesToDependents()) - { - // Targets using this archive need its language runtime libraries. - if(cmTarget::LinkImplementation const* impl = - this->GetLinkImplementation(config)) - { - iface.Languages = impl->Languages; - } - } - - if(this->GetType() == cmTarget::STATIC_LIBRARY) - { - // Construct the property name suffix for this configuration. - std::string suffix = "_"; - if(!config.empty()) - { - suffix += cmSystemTools::UpperCase(config); - } - else - { - suffix += "NOCONFIG"; - } - - // How many repetitions are needed if this library has cyclic - // dependencies? - std::string propName = "LINK_INTERFACE_MULTIPLICITY"; - propName += suffix; - if(const char* config_reps = this->GetProperty(propName)) - { - sscanf(config_reps, "%u", &iface.Multiplicity); - } - else if(const char* reps = - this->GetProperty("LINK_INTERFACE_MULTIPLICITY")) - { - sscanf(reps, "%u", &iface.Multiplicity); - } - } -} //---------------------------------------------------------------------------- void cmTargetInternals::AddInterfaceEntries( |