diff options
author | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2015-06-01 20:04:22 +0200 |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2015-10-01 16:19:36 +0000 |
commit | 5df87614e388640a4717ffcfeb478cc57575dd4e (patch) | |
tree | 61c2c7ecc2ccfedc726a58ea6448b252abf36709 /qmake/generators/win32/winmakefile.cpp | |
parent | cbbeed519b8bd98de71bd93c51c682f9d11158bd (diff) |
remove link_highest_lib_version misfeature
in retrospect, we were too conservative in 925fd32a2d8f making the
"feature" optional - it simply makes no sense to have qmake
automatically find the highest major (!) version of a library based on
a loosely defined platform-specific convention (not standard, unlike
ELF's .so versioning) with side effects.
Change-Id: Iba92df433b199a9fbff88358f6e0f6835f2e813d
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'qmake/generators/win32/winmakefile.cpp')
-rw-r--r-- | qmake/generators/win32/winmakefile.cpp | 24 |
1 files changed, 2 insertions, 22 deletions
diff --git a/qmake/generators/win32/winmakefile.cpp b/qmake/generators/win32/winmakefile.cpp index 2059cc7585..2d070e89e2 100644 --- a/qmake/generators/win32/winmakefile.cpp +++ b/qmake/generators/win32/winmakefile.cpp @@ -50,7 +50,7 @@ Win32MakefileGenerator::Win32MakefileGenerator() : MakefileGenerator() } int -Win32MakefileGenerator::findHighestVersion(const QString &d, const QString &stem, const QString &ext) +Win32MakefileGenerator::findHighestVersion(const QString &d, const QString &stem) { QString bd = Option::normalizePath(d); if(!exists(bd)) @@ -69,30 +69,10 @@ Win32MakefileGenerator::findHighestVersion(const QString &d, const QString &stem return vover.first().toInt(); int biggest=-1; - if (project->isActiveConfig("link_highest_lib_version")) { - static QHash<QString, QStringList> dirEntryListCache; - QStringList entries = dirEntryListCache.value(bd); - if (entries.isEmpty()) { - QDir dir(bd); - entries = dir.entryList(); - dirEntryListCache.insert(bd, entries); - } - - QRegExp regx(QString("((lib)?%1([0-9]*)).(%2|prl)$").arg(stem).arg(ext), Qt::CaseInsensitive); - for(QStringList::Iterator it = entries.begin(); it != entries.end(); ++it) { - if(regx.exactMatch((*it))) { - if (!regx.cap(3).isEmpty()) { - bool ok = true; - int num = regx.cap(3).toInt(&ok); - biggest = qMax(biggest, (!ok ? -1 : num)); - } - } - } - } if(libInfoRead && !libinfo.values("QMAKE_PRL_CONFIG").contains("staticlib") && !libinfo.isEmpty("QMAKE_PRL_VERSION")) - biggest = qMax(biggest, libinfo.first("QMAKE_PRL_VERSION").toQString().replace(".", "").toInt()); + biggest = libinfo.first("QMAKE_PRL_VERSION").toQString().replace(".", "").toInt(); return biggest; } |