diff options
| author | Harald Sitter <sitter@kde.org> | 2015-11-24 15:05:54 (GMT) |
|---|---|---|
| committer | Harald Sitter <sitter@kde.org> | 2015-11-25 12:01:47 (GMT) |
| commit | c46ff7074d593839e83de955d9c9751d7f496952 (patch) | |
| tree | 135c9985c3e6390c972cdab5bccb8db4e1a5bd85 | |
| parent | ce6e43e4f339590772589fda91fc4c5309021604 (diff) | |
implement name mangling to get qt5 dbg packages
| -rw-r--r-- | src/DebugFinder.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/DebugFinder.cpp b/src/DebugFinder.cpp index 8bf6d03..b8555aa 100644 --- a/src/DebugFinder.cpp +++ b/src/DebugFinder.cpp @@ -77,6 +77,19 @@ QApt::Package *DebugFinder::getDbgPkg(QApt::Package *package) return dbgPkg; } + // Qt 5 is spread over multiple sources, so static mapping would be + // rather error prone. Instead attempt to modify suitable source names + // according to convention and see if that yields a dbg package. + if (package->sourcePackage().endsWith(QStringLiteral("-opensource-src")) && + package->upstreamVersion().startsWith(QStringLiteral("5."))) { + // TODO: this possibly should simply repeat the entire function? + QString name = package->sourcePackage(); + name.replace(QStringLiteral("-opensource-src"), QStringLiteral("5")); + dbgPkg = m_backend->package(name + QStringLiteral("-dbg")); + if (dbgPkg) { + return dbgPkg; + } + } return nullptr; } |
