aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/qtprofilesetup/qtprofilesetup.cpp
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@theqtcompany.com>2015-06-18 10:19:55 +0200
committerChristian Kandeler <christian.kandeler@theqtcompany.com>2015-06-18 10:33:05 +0000
commita5b77c574ae5876cdb348bded7a3e091fe2f85bf (patch)
tree79797221508f9c37cfc2b89334c0a6bc6352663c /src/lib/qtprofilesetup/qtprofilesetup.cpp
parente9bd0dd08a080dd470593a0abfd9cfa27821752a (diff)
qtprofilesetup: Fix check for static Qt.
On Windows, the DLLs are in the BINS dir, not in LIBS. The reason this seemed to work so far is that the Qt packagers randomly put the DLLS into the LIBS directory for certain releases. For instance: Qt 5.4.2/MSVC: no Qt 5.4.2/MinGW: yes Qt 4.8.7/MinGW: yes Qt 4.8.6/MinGW: no Fun! Task-number: QBS-825 Change-Id: Ic717ced8b3c2269a8e4cc318704bd5ec7c7adadd Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'src/lib/qtprofilesetup/qtprofilesetup.cpp')
-rw-r--r--src/lib/qtprofilesetup/qtprofilesetup.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/qtprofilesetup/qtprofilesetup.cpp b/src/lib/qtprofilesetup/qtprofilesetup.cpp
index de5240a85..803f27923 100644
--- a/src/lib/qtprofilesetup/qtprofilesetup.cpp
+++ b/src/lib/qtprofilesetup/qtprofilesetup.cpp
@@ -265,13 +265,14 @@ static bool checkForStaticBuild(const QtEnvironment &qt)
return qt.qtConfigItems.contains(QLatin1String("static"));
if (qt.frameworkBuild)
return false; // there are no Qt4 static frameworks
- QDir libdir(qt.libraryPath);
+ const bool isWin = qt.mkspecName.startsWith(QLatin1String("win"));
+ const QDir libdir(isWin ? qt.binaryPath : qt.libraryPath);
const QStringList coreLibFiles
= libdir.entryList(QStringList(QLatin1String("*Core*")), QDir::Files);
if (coreLibFiles.isEmpty())
throw ErrorInfo(Internal::Tr::tr("Could not determine whether Qt is a static build."));
foreach (const QString &fileName, coreLibFiles) {
- if (QLibrary::isLibrary(qt.libraryPath + QLatin1Char('/') + fileName))
+ if (QLibrary::isLibrary(fileName))
return false;
}
return true;