diff options
author | Brad King <brad.king@kitware.com> | 2016-01-08 19:12:48 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2016-01-08 19:15:39 (GMT) |
commit | f086c665da00228cabf465dc1eb7223d40fd6270 (patch) | |
tree | 150aacf80d7e0a310c10de1106ec5446a14fca6e /Source/cmVisualStudio10TargetGenerator.cxx | |
parent | fd7180f0c0c2554c31afda235469df986a109fe4 (diff) | |
download | CMake-f086c665da00228cabf465dc1eb7223d40fd6270.zip CMake-f086c665da00228cabf465dc1eb7223d40fd6270.tar.gz CMake-f086c665da00228cabf465dc1eb7223d40fd6270.tar.bz2 |
VS: Fix VS 2015 .vcxproj file value for GenerateDebugInformation (#15894)
Starting with VS 2015 the GenerateDebugInformation build property is an
enumeration (`No`, `Debug`, `DebugFastLink`) instead of a boolean value
(`false`, `true`). For now we simply change to `No` and `Debug` fix
current behavior. Support for `/debug:fastlink` can be added later.
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r-- | Source/cmVisualStudio10TargetGenerator.cxx | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index 1de2847..6b46773 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -2579,11 +2579,27 @@ cmVisualStudio10TargetGenerator::ComputeLinkOptions(std::string const& config) if(linkOptions.IsDebug() || flags.find("/debug") != flags.npos) { - linkOptions.AddFlag("GenerateDebugInformation", "true"); + if (this->LocalGenerator->GetVersion() >= + cmGlobalVisualStudioGenerator::VS14) + { + linkOptions.AddFlag("GenerateDebugInformation", "Debug"); + } + else + { + linkOptions.AddFlag("GenerateDebugInformation", "true"); + } } else { - linkOptions.AddFlag("GenerateDebugInformation", "false"); + if (this->LocalGenerator->GetVersion() >= + cmGlobalVisualStudioGenerator::VS14) + { + linkOptions.AddFlag("GenerateDebugInformation", "No"); + } + else + { + linkOptions.AddFlag("GenerateDebugInformation", "false"); + } } std::string pdb = this->Target->GetPDBDirectory(config.c_str()); pdb += "/"; |