summaryrefslogtreecommitdiffstats
path: root/tools/configure
diff options
context:
space:
mode:
authorOliver Wolff <oliver.wolff@qt.io>2016-11-17 10:40:44 +0100
committerOliver Wolff <oliver.wolff@qt.io>2016-11-22 06:07:23 +0000
commit38675e18fcc841228141568a2ecfafdeb99eba2a (patch)
tree080bb7e04b926914ee5d2f05ead01dd8d9a56438 /tools/configure
parent0a203faa7f0bb836afbdd3addfba99190f69ff5f (diff)
Add support for Visual Studio 2017
Tested with RC Task-number: QTBUG-57086 Change-Id: I21f56edca3852b52edd2c5fdcce76817141e8d4a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'tools/configure')
-rw-r--r--tools/configure/configureapp.cpp3
-rw-r--r--tools/configure/environment.cpp6
-rw-r--r--tools/configure/environment.h3
3 files changed, 10 insertions, 2 deletions
diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp
index 88dcd8170b..a908db0707 100644
--- a/tools/configure/configureapp.cpp
+++ b/tools/configure/configureapp.cpp
@@ -1458,7 +1458,8 @@ void Configure::parseCmdLine()
dictionary[ "QMAKESPEC" ].endsWith("-msvc2010") ||
dictionary[ "QMAKESPEC" ].endsWith("-msvc2012") ||
dictionary[ "QMAKESPEC" ].endsWith("-msvc2013") ||
- dictionary[ "QMAKESPEC" ].endsWith("-msvc2015")) {
+ dictionary[ "QMAKESPEC" ].endsWith("-msvc2015") ||
+ dictionary[ "QMAKESPEC" ].endsWith("-msvc2017")) {
if (dictionary[ "MAKE" ].isEmpty()) dictionary[ "MAKE" ] = "nmake";
dictionary[ "QMAKEMAKEFILE" ] = "Makefile.win32";
} else if (dictionary[ "QMAKESPEC" ] == QString("win32-g++")) {
diff --git a/tools/configure/environment.cpp b/tools/configure/environment.cpp
index 153a141d7a..f950945597 100644
--- a/tools/configure/environment.cpp
+++ b/tools/configure/environment.cpp
@@ -76,6 +76,7 @@ struct CompilerInfo{
{CC_MSVC2013, "Microsoft (R) Visual Studio 2013 C/C++ Compiler (12.0)", "Software\\Microsoft\\VisualStudio\\SxS\\VC7\\12.0", "cl.exe"}, // link.exe, lib.exe
// Microsoft skipped version 13
{CC_MSVC2015, "Microsoft (R) Visual Studio 2015 C/C++ Compiler (14.0)", "Software\\Microsoft\\VisualStudio\\SxS\\VS7\\14.0", "cl.exe"}, // link.exe, lib.exe
+ {CC_MSVC2017, "Microsoft (R) Visual Studio 2017 C/C++ Compiler (15.0)", "Software\\Microsoft\\VisualStudio\\SxS\\VS7\\15.0", "cl.exe"}, // link.exe, lib.exe
{CC_UNKNOWN, "Unknown", 0, 0},
};
@@ -101,6 +102,9 @@ QString Environment::detectQMakeSpec()
{
QString spec;
switch (detectCompiler()) {
+ case CC_MSVC2017:
+ spec = "win32-msvc2017";
+ break;
case CC_MSVC2015:
spec = "win32-msvc2015";
break;
@@ -137,6 +141,8 @@ QString Environment::detectQMakeSpec()
Compiler Environment::compilerFromQMakeSpec(const QString &qmakeSpec)
{
+ if (qmakeSpec == QLatin1String("win32-msvc2017"))
+ return CC_MSVC2017;
if (qmakeSpec == QLatin1String("win32-msvc2015"))
return CC_MSVC2015;
if (qmakeSpec == QLatin1String("win32-msvc2013"))
diff --git a/tools/configure/environment.h b/tools/configure/environment.h
index d096782e70..6b0e9bb9fe 100644
--- a/tools/configure/environment.h
+++ b/tools/configure/environment.h
@@ -46,7 +46,8 @@ enum Compiler {
CC_MSVC2010 = 0xA0,
CC_MSVC2012 = 0xB0,
CC_MSVC2013 = 0xC0,
- CC_MSVC2015 = 0xD0
+ CC_MSVC2015 = 0xD0,
+ CC_MSVC2017 = 0xE0
};
struct CompilerInfo;