summaryrefslogtreecommitdiffstats
path: root/Source/cmVisualStudio10TargetGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-01-08 19:38:58 (GMT)
committerBrad King <brad.king@kitware.com>2016-01-11 14:45:00 (GMT)
commitb3677b35d320cce5d23831ec398d6bb283d1444e (patch)
tree7862fed73d4bfcacdbe368f1973a158b50d5742f /Source/cmVisualStudio10TargetGenerator.cxx
parentc22da7cff74a293d6362598c2a381147d658022f (diff)
downloadCMake-b3677b35d320cce5d23831ec398d6bb283d1444e.zip
CMake-b3677b35d320cce5d23831ec398d6bb283d1444e.tar.gz
CMake-b3677b35d320cce5d23831ec398d6bb283d1444e.tar.bz2
VS: Map the link `/debug` to its IDE property
Fix the link flag table entries for this flag to be case-insensitive. Also fix the VS 2015 value for the build property enumeration name. This causes `linkOptions.Parse(...)` to correctly extract the `/debug` flag and map it to the IDE property instead. Therefore we do not need to look for the flag explicitly when initializing the property.
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r--Source/cmVisualStudio10TargetGenerator.cxx24
1 files changed, 5 insertions, 19 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx
index 56f724f..2120035 100644
--- a/Source/cmVisualStudio10TargetGenerator.cxx
+++ b/Source/cmVisualStudio10TargetGenerator.cxx
@@ -2597,30 +2597,16 @@ cmVisualStudio10TargetGenerator::ComputeLinkOptions(std::string const& config)
linkOptions.AddFlag("StackReserveSize", stackVal);
}
- if(flags.find("/debug") != flags.npos)
+ if (this->LocalGenerator->GetVersion() >=
+ cmGlobalVisualStudioGenerator::VS14)
{
- if (this->LocalGenerator->GetVersion() >=
- cmGlobalVisualStudioGenerator::VS14)
- {
- linkOptions.AddFlag("GenerateDebugInformation", "Debug");
- }
- else
- {
- linkOptions.AddFlag("GenerateDebugInformation", "true");
- }
+ linkOptions.AddFlag("GenerateDebugInformation", "No");
}
else
{
- if (this->LocalGenerator->GetVersion() >=
- cmGlobalVisualStudioGenerator::VS14)
- {
- linkOptions.AddFlag("GenerateDebugInformation", "No");
- }
- else
- {
- linkOptions.AddFlag("GenerateDebugInformation", "false");
- }
+ linkOptions.AddFlag("GenerateDebugInformation", "false");
}
+
std::string pdb = this->GeneratorTarget->GetPDBDirectory(config.c_str());
pdb += "/";
pdb += targetNamePDB;