summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2016-10-07 18:13:33 (GMT)
committerStephen Kelly <steveire@gmail.com>2016-10-07 18:13:33 (GMT)
commit3b4895fa35e4a96022abd99b07002a7d2ab3a968 (patch)
treee985a95b71727c813ad6106eef311ffa01caf665
parent2232e97a6ed4a338b814d1ba3d62a7ffa9ef6e7f (diff)
downloadCMake-3b4895fa35e4a96022abd99b07002a7d2ab3a968.zip
CMake-3b4895fa35e4a96022abd99b07002a7d2ab3a968.tar.gz
CMake-3b4895fa35e4a96022abd99b07002a7d2ab3a968.tar.bz2
cmTarget: Inline MergeLinkLibraries into only caller
-rw-r--r--Source/cmMakefile.cxx11
-rw-r--r--Source/cmTarget.cxx13
-rw-r--r--Source/cmTarget.h3
3 files changed, 10 insertions, 17 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index df993ce..c022b44 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -1863,7 +1863,16 @@ void cmMakefile::AddGlobalLinkInformation(const std::string& name,
}
}
}
- target.MergeLinkLibraries(*this, name, this->LinkLibraries);
+
+ cmTarget::LinkLibraryVectorType::const_iterator i =
+ this->LinkLibraries.begin();
+ for (; i != this->LinkLibraries.end(); ++i) {
+ // This is equivalent to the target_link_libraries plain signature.
+ target.AddLinkLibrary(*this, name, i->first, i->second);
+ target.AppendProperty(
+ "INTERFACE_LINK_LIBRARIES",
+ target.GetDebugGeneratorExpressions(i->first, i->second).c_str());
+ }
}
void cmMakefile::AddAlias(const std::string& lname, std::string const& tgtName)
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 0e7e2a5..86a2777 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -476,19 +476,6 @@ cmSourceFile* cmTarget::AddSource(const std::string& src)
return this->Makefile->GetOrCreateSource(src);
}
-void cmTarget::MergeLinkLibraries(cmMakefile& mf, const std::string& selfname,
- const LinkLibraryVectorType& libs)
-{
- LinkLibraryVectorType::const_iterator i = libs.begin();
- for (; i != libs.end(); ++i) {
- // This is equivalent to the target_link_libraries plain signature.
- this->AddLinkLibrary(mf, selfname, i->first, i->second);
- this->AppendProperty(
- "INTERFACE_LINK_LIBRARIES",
- this->GetDebugGeneratorExpressions(i->first, i->second).c_str());
- }
-}
-
void cmTarget::AddLinkDirectory(const std::string& d)
{
// Make sure we don't add unnecessary search directories.
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index f062529..8fbb42f 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -153,9 +153,6 @@ public:
cmListFileContext const& lfc);
void GetTllSignatureTraces(std::ostream& s, TLLSignature sig) const;
- void MergeLinkLibraries(cmMakefile& mf, const std::string& selfname,
- const LinkLibraryVectorType& libs);
-
const std::vector<std::string>& GetLinkDirectories() const;
void AddLinkDirectory(const std::string& d);