summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalGenerator.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2016-10-08 10:21:37 (GMT)
committerStephen Kelly <steveire@gmail.com>2016-10-10 18:38:55 (GMT)
commitd48f69d0f5f265d1c091a614098cae3ff4325fbe (patch)
tree6c4022142d7684656a40e21f52c303cdb87a7d2d /Source/cmLocalGenerator.cxx
parentff8e321c6ade784b3f1b3b19a7783788872e44a9 (diff)
downloadCMake-d48f69d0f5f265d1c091a614098cae3ff4325fbe.zip
CMake-d48f69d0f5f265d1c091a614098cae3ff4325fbe.tar.gz
CMake-d48f69d0f5f265d1c091a614098cae3ff4325fbe.tar.bz2
cmLocalGenerator: Move flag determination up in the function
This content is independent of any targets.
Diffstat (limited to 'Source/cmLocalGenerator.cxx')
-rw-r--r--Source/cmLocalGenerator.cxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 9e32fd3..aec658a 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -1419,6 +1419,15 @@ void cmLocalGenerator::OutputLinkLibraries(
std::string libPathTerminator =
this->Makefile->GetSafeDefinition("CMAKE_LIBRARY_PATH_TERMINATOR");
+ // Add standard libraries for this language.
+ std::string standardLibsVar = "CMAKE_";
+ standardLibsVar += cli.GetLinkLanguage();
+ standardLibsVar += "_STANDARD_LIBRARIES";
+ std::string stdLibString;
+ if (const char* stdLibs = this->Makefile->GetDefinition(standardLibsVar)) {
+ stdLibString = stdLibs;
+ }
+
// Append the framework search path flags.
std::string fwSearchFlagVar = "CMAKE_";
fwSearchFlagVar += linkLanguage;
@@ -1502,14 +1511,6 @@ void cmLocalGenerator::OutputLinkLibraries(
fout << " ";
}
- // Add standard libraries for this language.
- std::string standardLibsVar = "CMAKE_";
- standardLibsVar += cli.GetLinkLanguage();
- standardLibsVar += "_STANDARD_LIBRARIES";
- std::string stdLibString;
- if (const char* stdLibs = this->Makefile->GetDefinition(standardLibsVar)) {
- stdLibString = stdLibs;
- }
if (!stdLibString.empty()) {
fout << stdLibString << " ";
}