summaryrefslogtreecommitdiffstats
path: root/qmake/generators/unix/unixmake.cpp
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@qt.io>2018-07-09 20:02:27 +0200
committerOswald Buddenhagen <oswald.buddenhagen@qt.io>2018-07-16 15:44:27 +0000
commit93362e26070c2beac16969b58be8349997921fc5 (patch)
tree7ba0b9602b2fe8b48bb35903b1a16651d6ea25a4 /qmake/generators/unix/unixmake.cpp
parentcaaceb30e6d998939f13eb6caccef6dbd49b9558 (diff)
qmake: slightly optimize processPrlFile() calls
add a parameter that indicates whether the passed filename can be only the basename of a prl file. if so, we can skip the other attempts at interpreting the file name. that's not only faster, but also clearer. Change-Id: I6f6da3f4485216021282a08acaefb53e60e7242a Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'qmake/generators/unix/unixmake.cpp')
-rw-r--r--qmake/generators/unix/unixmake.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/qmake/generators/unix/unixmake.cpp b/qmake/generators/unix/unixmake.cpp
index 894020d2bd..52d34ef513 100644
--- a/qmake/generators/unix/unixmake.cpp
+++ b/qmake/generators/unix/unixmake.cpp
@@ -443,7 +443,7 @@ UnixMakefileGenerator::findLibraries(bool linkPrl, bool mergeLflags)
dep_it != libdirs.end(); ++dep_it) {
QString libBase = (*dep_it).local() + '/'
+ project->first("QMAKE_PREFIX_SHLIB") + lib;
- if (linkPrl && processPrlFile(libBase))
+ if (linkPrl && processPrlFile(libBase, true))
goto found;
for (ProStringList::Iterator extit = extens.begin(); extit != extens.end(); ++extit) {
if (exists(libBase + '.' + (*extit)))
@@ -471,12 +471,12 @@ UnixMakefileGenerator::findLibraries(bool linkPrl, bool mergeLflags)
}
for (const QMakeLocalFileName &dir : qAsConst(frameworkdirs)) {
QString frameworkDirectory = dir.local() + "/" + frameworkName + + ".framework/";
- QString suffixedPrl = frameworkDirectory + opt + Option::prl_ext;
- if (processPrlFile(suffixedPrl))
+ QString suffixedPrl = frameworkDirectory + opt;
+ if (processPrlFile(suffixedPrl, true))
break;
if (hasSuffix) {
- QString unsuffixedPrl = frameworkDirectory + frameworkName + Option::prl_ext;
- if (processPrlFile(unsuffixedPrl))
+ QString unsuffixedPrl = frameworkDirectory + frameworkName;
+ if (processPrlFile(unsuffixedPrl, true))
break;
}
}
@@ -487,7 +487,7 @@ UnixMakefileGenerator::findLibraries(bool linkPrl, bool mergeLflags)
}
}
} else if (linkPrl) {
- processPrlFile(opt);
+ processPrlFile(opt, false);
}
ProStringList &prl_libs = project->values("QMAKE_CURRENT_PRL_LIBS");