summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-11-30 13:37:11 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2016-11-30 13:37:11 (GMT)
commit4288708cbad644b26468769e287dfd06b974ced9 (patch)
tree646473a89711810b42296e8690bc1690868a5c4e /Source
parent996e5237cad257b94c55cb788e8175e474b6696f (diff)
parent31e013ae6066067433676c21b8698256404d64f1 (diff)
downloadCMake-4288708cbad644b26468769e287dfd06b974ced9.zip
CMake-4288708cbad644b26468769e287dfd06b974ced9.tar.gz
CMake-4288708cbad644b26468769e287dfd06b974ced9.tar.bz2
Merge topic 'vs15-rename-generator-for-master'
31e013ae Merge branch 'vs15-rename-generator' into vs15-rename-generator-for-master d639620e VS: Rename VS 15 generator to 'Visual Studio 15 2017'
Diffstat (limited to 'Source')
-rw-r--r--Source/cmGlobalVisualStudio15Generator.cxx11
-rw-r--r--Source/cmake.cxx2
2 files changed, 8 insertions, 5 deletions
diff --git a/Source/cmGlobalVisualStudio15Generator.cxx b/Source/cmGlobalVisualStudio15Generator.cxx
index 19b48df..091a03e 100644
--- a/Source/cmGlobalVisualStudio15Generator.cxx
+++ b/Source/cmGlobalVisualStudio15Generator.cxx
@@ -8,16 +8,19 @@
#include "cmMakefile.h"
#include "cmVS141CLFlagTable.h"
-static const char vs15generatorName[] = "Visual Studio 15";
+static const char vs15generatorName[] = "Visual Studio 15 2017";
// Map generator name without year to name with year.
static const char* cmVS15GenName(const std::string& name, std::string& genName)
{
if (strncmp(name.c_str(), vs15generatorName,
- sizeof(vs15generatorName) - 1) != 0) {
+ sizeof(vs15generatorName) - 6) != 0) {
return 0;
}
- const char* p = name.c_str() + sizeof(vs15generatorName) - 1;
+ const char* p = name.c_str() + sizeof(vs15generatorName) - 6;
+ if (cmHasLiteralPrefix(p, " 2017")) {
+ p += 5;
+ }
genName = std::string(vs15generatorName) + p;
return p;
}
@@ -52,7 +55,7 @@ public:
virtual void GetDocumentation(cmDocumentationEntry& entry) const
{
entry.Name = std::string(vs15generatorName) + " [arch]";
- entry.Brief = "Generates Visual Studio 15 project files. "
+ entry.Brief = "Generates Visual Studio 2017 project files. "
"Optional [arch] can be \"Win64\" or \"ARM\".";
}
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 59290ff..733e0e4 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -1457,7 +1457,7 @@ void cmake::CreateDefaultGlobalGenerator()
const char* GeneratorName;
};
static VSVersionedGenerator const vsGenerators[] = {
- { "15.0", "Visual Studio 15" }, //
+ { "15.0", "Visual Studio 15 2017" }, //
{ "14.0", "Visual Studio 14 2015" }, //
{ "12.0", "Visual Studio 12 2013" }, //
{ "11.0", "Visual Studio 11 2012" }, //