diff options
author | Stephen Kelly <steveire@gmail.com> | 2016-10-09 08:47:44 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2016-10-10 14:09:54 (GMT) |
commit | 3d0e95f64c996d3d54b387f7688f988dd843ac6a (patch) | |
tree | 14532a8c6784eff34dca62aab9817062962afe98 /Source/cmLocalGenerator.cxx | |
parent | 2a49d86d5dec66f7696bd7063459f504cc336a5e (diff) | |
download | CMake-3d0e95f64c996d3d54b387f7688f988dd843ac6a.zip CMake-3d0e95f64c996d3d54b387f7688f988dd843ac6a.tar.gz CMake-3d0e95f64c996d3d54b387f7688f988dd843ac6a.tar.bz2 |
cmLocalGenerator: Extract definition retrieval out of loop
Diffstat (limited to 'Source/cmLocalGenerator.cxx')
-rw-r--r-- | Source/cmLocalGenerator.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 2284cf9..025b82a 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -1176,12 +1176,13 @@ void cmLocalGenerator::GetTargetFlags( !(this->Makefile->IsOn("CYGWIN") || this->Makefile->IsOn("MINGW"))) { std::vector<cmSourceFile*> sources; target->GetSourceFiles(sources, buildType); + std::string defFlag = + this->Makefile->GetSafeDefinition("CMAKE_LINK_DEF_FILE_FLAG"); for (std::vector<cmSourceFile*>::const_iterator i = sources.begin(); i != sources.end(); ++i) { cmSourceFile* sf = *i; if (sf->GetExtension() == "def") { - linkFlags += - this->Makefile->GetSafeDefinition("CMAKE_LINK_DEF_FILE_FLAG"); + linkFlags += defFlag; linkFlags += this->ConvertToOutputFormat( cmSystemTools::CollapseFullPath(sf->GetFullPath()), SHELL); linkFlags += " "; |