summaryrefslogtreecommitdiffstats
path: root/src/windeployqt/main.cpp
diff options
context:
space:
mode:
authorOliver Wolff <oliver.wolff@qt.io>2018-03-21 12:52:13 +0100
committerSami Nurmenniemi <sami.nurmenniemi@qt.io>2018-04-06 13:21:17 +0000
commit70ac977a7293833fd5a4a467e217e64fd42b1a17 (patch)
tree0290149db5459ea39e0376a6b8f43430bc6c5443 /src/windeployqt/main.cpp
parente02d2e9061a2fd884590c0ebfba6406dbf17cabe (diff)
Rename Windows(MinGW) to WindowsDesktop(MinGW) in Platform enum
When used in connection with a winrt related header (roerrorapi.h) having an enum value Windows will lead to a symbol redefinition error, because Windows is used as a namespace name in there. Change-Id: Ie102b0d7a72ffb01c3a97f5f5f51b1645d46342b Reviewed-by: Andre de la Rocha <andre.rocha@qt.io> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'src/windeployqt/main.cpp')
-rw-r--r--src/windeployqt/main.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/windeployqt/main.cpp b/src/windeployqt/main.cpp
index 86ca9e2f9..bbecc7f97 100644
--- a/src/windeployqt/main.cpp
+++ b/src/windeployqt/main.cpp
@@ -194,7 +194,7 @@ static Platform platformFromMkSpec(const QString &xSpec)
if (xSpec == QLatin1String("linux-g++"))
return Unix;
if (xSpec.startsWith(QLatin1String("win32-")))
- return xSpec.contains(QLatin1String("g++")) ? WindowsMinGW : Windows;
+ return xSpec.contains(QLatin1String("g++")) ? WindowsDesktopMinGW : WindowsDesktop;
if (xSpec.startsWith(QLatin1String("winrt-x")))
return WinRtIntel;
if (xSpec.startsWith(QLatin1String("winrt-arm")))
@@ -255,7 +255,7 @@ struct Options {
bool compilerRunTime = false;
AngleDetection angleDetection = AngleDetectionAuto;
bool softwareRasterizer = true;
- Platform platform = Windows;
+ Platform platform = WindowsDesktop;
quint64 additionalLibraries = 0;
quint64 disabledLibraries = 0;
unsigned updateFileFlags = 0;
@@ -481,7 +481,7 @@ static inline int parseArguments(const QStringList &arguments, QCommandLineParse
else if (parser->isSet(noCompilerRunTimeOption))
options->compilerRunTime = false;
- if (options->compilerRunTime && options->platform != WindowsMinGW && options->platform != Windows) {
+ if (options->compilerRunTime && options->platform != WindowsDesktopMinGW && options->platform != WindowsDesktop) {
*errorMessage = QStringLiteral("Deployment of the compiler runtime is implemented for Desktop only.");
return CommandLineParseError;
}
@@ -889,8 +889,8 @@ QStringList findQtPlugins(quint64 *usedQtModules, quint64 disabledQtModules,
const bool isPlatformPlugin = subDirName == QLatin1String("platforms");
if (isPlatformPlugin) {
switch (platform) {
- case Windows:
- case WindowsMinGW:
+ case WindowsDesktop:
+ case WindowsDesktopMinGW:
case WinCEIntel:
case WinCEArm:
filter = QStringLiteral("qwindows");
@@ -1084,7 +1084,7 @@ static QStringList compilerRunTimeLibs(Platform platform, bool isDebug, unsigned
{
QStringList result;
switch (platform) {
- case WindowsMinGW: { // MinGW: Add runtime libraries
+ case WindowsDesktopMinGW: { // MinGW: Add runtime libraries
static const char *minGwRuntimes[] = {"*gcc_", "*stdc++", "*winpthread"};
const QString gcc = findInPath(QStringLiteral("g++.exe"));
if (gcc.isEmpty()) {
@@ -1102,7 +1102,7 @@ static QStringList compilerRunTimeLibs(Platform platform, bool isDebug, unsigned
result.append(dllFi.absoluteFilePath());
}
break;
- case Windows: { // MSVC/Desktop: Add redistributable packages.
+ case WindowsDesktop: { // MSVC/Desktop: Add redistributable packages.
QString vcRedistDirName = vcRedistDir();
if (vcRedistDirName.isEmpty())
break;
@@ -1644,7 +1644,7 @@ int main(int argc, char **argv)
const QMap<QString, QString> qmakeVariables = queryQMakeAll(&errorMessage);
const QString xSpec = qmakeVariables.value(QStringLiteral("QMAKE_XSPEC"));
options.platform = platformFromMkSpec(xSpec);
- if (options.platform == WindowsMinGW || options.platform == Windows)
+ if (options.platform == WindowsDesktopMinGW || options.platform == WindowsDesktop)
options.compilerRunTime = true;
{ // Command line