diff options
author | Christian Kandeler <christian.kandeler@qt.io> | 2017-04-19 14:38:41 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@qt.io> | 2017-04-20 07:49:35 +0000 |
commit | d5542fa418045d5ff7b8a1af33761ee245407841 (patch) | |
tree | c599aca1cbe1a532684ac3773e8ea1de4ab45922 | |
parent | 6852cc3556cc6afecd517df133fa22f14b4801aa (diff) |
libqtprofilesetup: Turn "-pthread" into "-lpthread"
Otherwise we get errors, because we interpret generic options as linker
flags, but -pthread is a driver option.
Add a warning for all other "raw" options encountered on the right-hand
side of QMAKE_PRL_LIBS, as those are not expected there.
Change-Id: If4555caff886c691bddf3ee17bbe7490f9b8fc12
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
-rw-r--r-- | src/lib/qtprofilesetup/qtmoduleinfo.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/qtprofilesetup/qtmoduleinfo.cpp b/src/lib/qtprofilesetup/qtmoduleinfo.cpp index 91215a9f2..e0e35988c 100644 --- a/src/lib/qtprofilesetup/qtmoduleinfo.cpp +++ b/src/lib/qtprofilesetup/qtmoduleinfo.cpp @@ -289,7 +289,11 @@ void QtModuleInfo::setupLibraries(const QtEnvironment &qtEnv, bool debugBuild, } else if (part == QLatin1String("-framework")) { if (++i < parts.count()) frameworks << parts.at(i); - } else if (part.startsWith(QLatin1Char('-'))) { // Some other option, e.g. "-pthread". + } else if (part == QLatin1String("-pthread")) { + libs << QLatin1String("pthread"); + } else if (part.startsWith(QLatin1Char('-'))) { // Some other option + qDebug("QMAKE_PRL_LIBS contains non-library option '%s' in file '%s'", + qPrintable(part), qPrintable(prlFilePath)); flags << part; } else if (part.startsWith(QLatin1String("/LIBPATH:"))) { libraryPaths << part.mid(9).replace(QLatin1String("\\\\"), QLatin1String("/")); |