[CMake] CMAKE_SHARED_LINKER_FLAGS_<build_type> flag ignored on VC generators

Ian.Appru at ubs.com Ian.Appru at ubs.com
Thu Jan 26 07:38:17 EST 2006


Hi 

I'm using a copy of CMake from cvs and have found that the
CMAKE_SHARED_LINKER_FLAGS_<build_type> flags are ignored by the VC
generators.

I have made a fix to the localVC7 generator -see below - but vc6 and
perhaps vc8 still need attention.

- Ian



std::string
cmLocalVisualStudio7Generator::GetBuildTypeLinkerFlags(std::string
rootLinkerFlags, const char* configName)
{
  std::string configTypeUpper = cmSystemTools::UpperCase(configName);
  std::string extraLinkOptionsBuildTypeDef = rootLinkerFlags + "_" +
configTypeUpper;

  std::string extraLinkOptionsBuildType = 
 
m_Makefile->GetRequiredDefinition(extraLinkOptionsBuildTypeDef.c_str());

  return extraLinkOptionsBuildType;
}

void cmLocalVisualStudio7Generator::OutputBuildTool(...
...
...
  if(target.GetType() == cmTarget::SHARED_LIBRARY)
    {
    extraLinkOptions =
m_Makefile->GetRequiredDefinition("CMAKE_SHARED_LINKER_FLAGS") +
      std::string(" ") +
GetBuildTypeLinkerFlags("CMAKE_SHARED_LINKER_FLAGS", configName);
    }



Visit our website at http://www.ubs.com

This message contains confidential information and is intended only 
for the individual named.  If you are not the named addressee you 
should not disseminate, distribute or copy this e-mail.  Please 
notify the sender immediately by e-mail if you have received this 
e-mail by mistake and delete this e-mail from your system.

E-mail transmission cannot be guaranteed to be secure or error-free 
as information could be intercepted, corrupted, lost, destroyed, 
arrive late or incomplete, or contain viruses.  The sender therefore 
does not accept liability for any errors or omissions in the contents 
of this message which arise as a result of e-mail transmission.  If 
verification is required please request a hard-copy version.  This 
message is provided for informational purposes and should not be 
construed as a solicitation or offer to buy or sell any securities or 
related financial instruments.
-------------- next part --------------
Skipped content of type multipart/mixed


More information about the CMake mailing list