diff options
-rw-r--r-- | qmake/generators/makefile.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp index d422dfe4c2..b27c7f4912 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp @@ -889,9 +889,10 @@ MakefileGenerator::processPrlFile(QString &file, bool baseOnly) if (!meta_file.isEmpty()) { try_replace_file = true; } else if (!baseOnly) { - int ext = f.lastIndexOf('.'); + int off = qMax(f.lastIndexOf('/'), f.lastIndexOf('\\')) + 1; + int ext = f.midRef(off).lastIndexOf('.'); if (ext != -1) - meta_file = QMakeMetaInfo::checkLib(f.left(ext) + Option::prl_ext); + meta_file = QMakeMetaInfo::checkLib(f.leftRef(off + ext) + Option::prl_ext); } } if (meta_file.isEmpty()) |