VS6: Add handling of CMAKE_*_LINKER_FLAGS_<CONFIG> variables

Read the content of the config specific linker flags in the
Visual Studio 6 generator too.
This commit is contained in:
Patrick Gansterer 2013-07-30 12:23:50 +02:00 committed by Brad King
parent 152dfdab11
commit 33e6e0b9c2
1 changed files with 30 additions and 6 deletions

View File

@ -1171,18 +1171,42 @@ void cmLocalVisualStudio6Generator
std::string extraLinkOptionsRelWithDebInfo;
if(target.GetType() == cmTarget::EXECUTABLE)
{
extraLinkOptions =
this->Makefile->GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS");
extraLinkOptions = this->Makefile->
GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS");
extraLinkOptionsDebug = this->Makefile->
GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS_DEBUG");
extraLinkOptionsRelease = this->Makefile->
GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS_RELEASE");
extraLinkOptionsMinSizeRel = this->Makefile->
GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS_MINSIZEREL");
extraLinkOptionsRelWithDebInfo = this->Makefile->
GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO");
}
if(target.GetType() == cmTarget::SHARED_LIBRARY)
{
extraLinkOptions =
this->Makefile->GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS");
extraLinkOptions = this->Makefile->
GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS");
extraLinkOptionsDebug = this->Makefile->
GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS_DEBUG");
extraLinkOptionsRelease = this->Makefile->
GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS_RELEASE");
extraLinkOptionsMinSizeRel = this->Makefile->
GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL");
extraLinkOptionsRelWithDebInfo = this->Makefile->
GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO");
}
if(target.GetType() == cmTarget::MODULE_LIBRARY)
{
extraLinkOptions =
this->Makefile->GetRequiredDefinition("CMAKE_MODULE_LINKER_FLAGS");
extraLinkOptions = this->Makefile->
GetRequiredDefinition("CMAKE_MODULE_LINKER_FLAGS");
extraLinkOptionsDebug = this->Makefile->
GetRequiredDefinition("CMAKE_MODULE_LINKER_FLAGS_DEBUG");
extraLinkOptionsRelease = this->Makefile->
GetRequiredDefinition("CMAKE_MODULE_LINKER_FLAGS_RELEASE");
extraLinkOptionsMinSizeRel = this->Makefile->
GetRequiredDefinition("CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL");
extraLinkOptionsRelWithDebInfo = this->Makefile->
GetRequiredDefinition("CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO");
}
// Get extra linker options for this target.