Fix qtbase build for MSVC 2017 15.8

Fixed breaks caused by MSVC 2017 15.8 fixing std::aligned_storage.

Change-Id: I5adea18c184e34bbdc3bd294d034b97383ef08a3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Thomas Miller 2018-07-24 14:52:04 -07:00
parent ce4407c327
commit 0ef66e98cc
2 changed files with 7 additions and 1 deletions

View File

@ -110,6 +110,12 @@ greaterThan(QMAKE_MSC_VER, 1909) {
QMAKE_CXXFLAGS_CXX14 = -std:c++14
QMAKE_CXXFLAGS_CXX1Z = -std:c++17
}
# MSVC 2017 15.8+ fixed std::aligned_storage but compilation fails without
# this flag since the fix breaks binary compatibility.
greaterThan(QMAKE_MSC_VER, 1914) {
DEFINES += _ENABLE_EXTENDED_ALIGNED_STORAGE
}
}
greaterThan(QMAKE_MSC_VER, 1910) {

View File

@ -39,7 +39,7 @@ CFLAGS_BARE = -c -Fo./ -Fdqmake.pdb \
-D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS \
-DQT_VERSION_STR=\"$(QT_VERSION)\" -DQT_VERSION_MAJOR=$(QT_MAJOR_VERSION) -DQT_VERSION_MINOR=$(QT_MINOR_VERSION) -DQT_VERSION_PATCH=$(QT_PATCH_VERSION) \
-DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL \
-DQT_NO_FOREACH -DUNICODE
-DQT_NO_FOREACH -DUNICODE -D_ENABLE_EXTENDED_ALIGNED_STORAGE
CFLAGS = $(CFLAGS_PCH) $(CFLAGS_BARE) $(CFLAGS)
CXXFLAGS_BARE = $(CFLAGS_BARE)