diff options
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r-- | Source/cmGlobalXCodeGenerator.cxx | 34 |
1 files changed, 19 insertions, 15 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx index 63de1a5..7cb2d1f 100644 --- a/Source/cmGlobalXCodeGenerator.cxx +++ b/Source/cmGlobalXCodeGenerator.cxx @@ -1769,27 +1769,31 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmTarget& target, configName); } - const char* linkFlagsProp = "LINK_FLAGS"; if(target.GetType() == cmTarget::OBJECT_LIBRARY || target.GetType() == cmTarget::STATIC_LIBRARY) { - linkFlagsProp = "STATIC_LIBRARY_FLAGS"; - } - const char* targetLinkFlags = target.GetProperty(linkFlagsProp); - if(targetLinkFlags) - { - extraLinkOptions += " "; - extraLinkOptions += targetLinkFlags; + this->CurrentLocalGenerator + ->GetStaticLibraryFlags(extraLinkOptions, + cmSystemTools::UpperCase(configName), + &target); } - if(configName && *configName) + else { - std::string linkFlagsVar = linkFlagsProp; - linkFlagsVar += "_"; - linkFlagsVar += cmSystemTools::UpperCase(configName); - if(const char* linkFlags = target.GetProperty(linkFlagsVar.c_str())) + const char* targetLinkFlags = target.GetProperty("LINK_FLAGS"); + if(targetLinkFlags) { - extraLinkOptions += " "; - extraLinkOptions += linkFlags; + this->CurrentLocalGenerator-> + AppendFlags(extraLinkOptions, targetLinkFlags); + } + if(configName && *configName) + { + std::string linkFlagsVar = "LINK_FLAGS_"; + linkFlagsVar += cmSystemTools::UpperCase(configName); + if(const char* linkFlags = target.GetProperty(linkFlagsVar.c_str())) + { + this->CurrentLocalGenerator-> + AppendFlags(extraLinkOptions, linkFlags); + } } } |