From 221a09ef37aa8ff2cd5be069cc77aee6cb1f467a Mon Sep 17 00:00:00 2001 From: Sam James Date: Sat, 6 Dec 2025 11:13:15 +0000 Subject: [PATCH] dev-debug/hotspot: new package, add 1.5.1_p20250907, 9999 Take a snapshot as upstream releases seem infrequent and we'd have to backport a few patches if using the last release, and I already did the dep work for master. Based on the ebuild from ::kdab-overlay [0]. [0] https://github.com/KDAB/kdab-overlay/blob/640bf73ef28e111778bce61e3c93f19f6ddd0fdd/dev-util/hotspot/hotspot-1.5.1.ebuild Closes: https://bugs.gentoo.org/624062 Signed-off-by: Sam James --- dev-debug/hotspot/Manifest | 3 + dev-debug/hotspot/files/hotspot-odr.patch | 234 ++++++++++++++++++ .../hotspot/hotspot-1.5.1_p20250907.ebuild | 124 ++++++++++ dev-debug/hotspot/hotspot-9999.ebuild | 124 ++++++++++ dev-debug/hotspot/metadata.xml | 14 ++ 5 files changed, 499 insertions(+) create mode 100644 dev-debug/hotspot/Manifest create mode 100644 dev-debug/hotspot/files/hotspot-odr.patch create mode 100644 dev-debug/hotspot/hotspot-1.5.1_p20250907.ebuild create mode 100644 dev-debug/hotspot/hotspot-9999.ebuild create mode 100644 dev-debug/hotspot/metadata.xml diff --git a/dev-debug/hotspot/Manifest b/dev-debug/hotspot/Manifest new file mode 100644 index 000000000000..f7871c71df62 --- /dev/null +++ b/dev-debug/hotspot/Manifest @@ -0,0 +1,3 @@ +DIST PrefixTickLabels-7cd6d5a04cf3747cc9327efdbcbf43620efaa0c1.gh.tar.gz 21553 BLAKE2B c804b6a573db0015fea032c4e1497d19e70a6d1fac85e980a8a9467bb773b583be0e4ffcc92802083760c56541fc17f3f5ed698f34913e49451a064768a4ad7f SHA512 d0f9d5f1e4b597f55d612bdcb9c870f0a490a5c66cb72e10bb1e73278be3f33bfb0a9c4ba0f4dfd3973f030814b594f9225f9d49a190de176961aa7677287d6f +DIST hotspot-b61451d827dd23e35c5f611e3626226a119dfa48.gh.tar.gz 4103942 BLAKE2B 0ccdc66f1bde032c981d49807a659589ac51023f747afc462a75c27594cc806e67b3ec9525e0236da568c1ecf8f1d4fefcbd539ed5577f9a23850b20a478671b SHA512 e77111fe9213b24aca6070eb21ea1e608dd30472bf72d6433a5e72f2d8e17926bee169aa70820776dbcb966e610fef43f0091db98443e929a2fb1437956f7300 +DIST perfparser-65472541f74da213583535c8bb4fea831e875109.gh.tar.gz 3312538 BLAKE2B d2443e60c93047d7f5714d56ed24e5d3f94ace7cef152a6ea70539f8c0e0eb720297635da122715cd07f7efacbed9010951d368f1fc94142a5ebd130ea39377e SHA512 7ee0ec21dfdc201618921d1878c19c32cafecb268ecf45b513048730d8c34202fd28b531ec938ef13666d7b5dd83b75b68f33a607a6e016fcd8759af980bb223 diff --git a/dev-debug/hotspot/files/hotspot-odr.patch b/dev-debug/hotspot/files/hotspot-odr.patch new file mode 100644 index 000000000000..75f11ad1b698 --- /dev/null +++ b/dev-debug/hotspot/files/hotspot-odr.patch @@ -0,0 +1,234 @@ +--- a/src/models/disassemblymodel.cpp ++++ b/src/models/disassemblymodel.cpp +@@ -240,7 +240,7 @@ QModelIndex DisassemblyModel::indexForFileLine(const Data::FileLine& fileLine) c + return index(bestMatch, 0); + } + +-void DisassemblyModel::find(const QString& search, Direction direction, int current) ++void DisassemblyModel::find(const QString& search, SearchDirection direction, int current) + { + auto searchFunc = [&search](const DisassemblyOutput::DisassemblyLine& line) { + return line.disassembly.indexOf(search, 0, Qt::CaseInsensitive) != -1; +--- a/src/models/disassemblymodel.h ++++ b/src/models/disassemblymodel.h +@@ -20,7 +20,7 @@ class Definition; + class Repository; + } + +-enum class Direction; ++enum class SearchDirection; + + class DisassemblyModel : public QAbstractTableModel + { +@@ -76,7 +76,7 @@ signals: + + public slots: + void updateHighlighting(int line); +- void find(const QString& search, Direction direction, int offset); ++ void find(const QString& search, SearchDirection direction, int offset); + void scrollToLine(const QString& lineNumber); + + private: +--- a/src/models/search.h ++++ b/src/models/search.h +@@ -10,7 +10,7 @@ + #include + #include + +-enum class Direction ++enum class SearchDirection + { + Forward, + Backward +@@ -45,7 +45,7 @@ int search_helper(const it begin, const it end, const it current, SearchFunc sea + } + + template +-int search(const it begin, const it end, int current, Direction direction, SearchFunc searchFunc, EndReached endReached) ++int search(const it begin, const it end, int current, SearchDirection direction, SearchFunc searchFunc, EndReached endReached) + { + if (begin == end) + return -1; +@@ -54,7 +54,7 @@ int search(const it begin, const it end, int current, Direction direction, Searc + current = std::clamp(current, 0, static_cast(size) - 1); + const auto currentIt = begin + current; + +- if (direction == Direction::Forward) { ++ if (direction == SearchDirection::Forward) { + return search_helper(begin, end, std::next(currentIt), searchFunc, endReached); + } + +--- a/src/models/sourcecodemodel.cpp ++++ b/src/models/sourcecodemodel.cpp +@@ -258,7 +258,7 @@ void SourceCodeModel::setSysroot(const QString& sysroot) + m_sysroot = sysroot; + } + +-void SourceCodeModel::find(const QString& search, Direction direction, int current) ++void SourceCodeModel::find(const QString& search, SearchDirection direction, int current) + { + auto searchFunc = [&search](const QString& line) { return line.indexOf(search, 0, Qt::CaseInsensitive) != -1; }; + +--- a/src/models/sourcecodemodel.h ++++ b/src/models/sourcecodemodel.h +@@ -20,7 +20,7 @@ class Repository; + class Definition; + } + +-enum class Direction; ++enum class SearchDirection; + + Q_DECLARE_METATYPE(QTextLine) + +@@ -73,7 +73,7 @@ public slots: + void updateHighlighting(int line); + void setSysroot(const QString& sysroot); + +- void find(const QString& search, Direction direction, int current); ++ void find(const QString& search, SearchDirection direction, int current); + void scrollToLine(const QString& lineNumber); + + private: +--- a/src/resultsdisassemblypage.cpp ++++ b/src/resultsdisassemblypage.cpp +@@ -407,12 +407,12 @@ ResultsDisassemblyPage::ResultsDisassemblyPage(CostContextMenu* costContextMenu, + + auto searchNext = [model, edit, additionalRows, searchResultIndex] { + const auto offset = searchResultIndex->isValid() ? searchResultIndex->row() - additionalRows : 0; +- model->find(edit->text(), Direction::Forward, offset); ++ model->find(edit->text(), SearchDirection::Forward, offset); + }; + + auto searchPrev = [model, edit, additionalRows, searchResultIndex] { + const auto offset = searchResultIndex->isValid() ? searchResultIndex->row() - additionalRows : 0; +- model->find(edit->text(), Direction::Backward, offset); ++ model->find(edit->text(), SearchDirection::Backward, offset); + }; + + auto findNextAction = KStandardAction::findNext(this, searchNext, actions); +--- a/tests/modeltests/tst_models.cpp ++++ b/tests/modeltests/tst_models.cpp +@@ -514,7 +514,7 @@ private slots: + // check if search works in general + QSignalSpy searchSpy(&model, &SourceCodeModel::resultFound); + for (int i = 0; i < 5; i++) { +- model.find(QStringLiteral("Line 5"), Direction::Forward, i); ++ model.find(QStringLiteral("Line 5"), SearchDirection::Forward, i); + auto result = searchSpy.takeFirst(); + QCOMPARE(result.at(0).value(), model.index(3, SourceCodeModel::SourceCodeColumn)); + } +@@ -522,21 +522,21 @@ private slots: + // Check wrap around + for (int i = 1; i < 4; i++) { + QSignalSpy endReached(&model, &SourceCodeModel::searchEndReached); +- model.find(QStringLiteral("Line 3"), Direction::Forward, i); ++ model.find(QStringLiteral("Line 3"), SearchDirection::Forward, i); + QCOMPARE(endReached.size(), 1); + } + + // check if no result found works + searchSpy.clear(); + for (int i = 0; i < 5; i++) { +- model.find(QStringLiteral("Line 8"), Direction::Forward, i); ++ model.find(QStringLiteral("Line 8"), SearchDirection::Forward, i); + auto result = searchSpy.takeFirst(); + QCOMPARE(result.at(0).value().isValid(), false); + } + + // test backward search + for (int i = 4; i > 0; i--) { +- model.find(QStringLiteral("Line 7"), Direction::Backward, i); ++ model.find(QStringLiteral("Line 7"), SearchDirection::Backward, i); + auto result = searchSpy.takeFirst(); + QCOMPARE(result.at(0).value(), model.index(5, SourceCodeModel::SourceCodeColumn)); + } +@@ -544,14 +544,14 @@ private slots: + // Check wrap around + for (int i = 4; i > 0; i--) { + QSignalSpy endReached(&model, &SourceCodeModel::searchEndReached); +- model.find(QStringLiteral("Line 7"), Direction::Backward, i); ++ model.find(QStringLiteral("Line 7"), SearchDirection::Backward, i); + QCOMPARE(endReached.size(), 1); + } + + // check if no result found works + searchSpy.clear(); + for (int i = 0; i < 5; i++) { +- model.find(QStringLiteral("Line 8"), Direction::Backward, i); ++ model.find(QStringLiteral("Line 8"), SearchDirection::Backward, i); + auto result = searchSpy.takeFirst(); + QCOMPARE(result.at(0).value().isValid(), false); + } +--- a/tests/modeltests/tst_search.cpp ++++ b/tests/modeltests/tst_search.cpp +@@ -24,9 +24,9 @@ private slots: + const std::array testArray = {}; + + QCOMPARE( +- search(testArray.cbegin(), testArray.cend(), 0, Direction::Forward, [](int) { return false; }, [] {}), -1); ++ search(testArray.cbegin(), testArray.cend(), 0, SearchDirection::Forward, [](int) { return false; }, [] {}), -1); + QCOMPARE( +- search(testArray.cbegin(), testArray.cend(), 0, Direction::Backward, [](int) { return false; }, [] {}), -1); ++ search(testArray.cbegin(), testArray.cend(), 0, SearchDirection::Backward, [](int) { return false; }, [] {}), -1); + } + void testSearch() + { +@@ -35,11 +35,11 @@ private slots: + int maxOffset = testArray.size() - 1; + for (int offset = 0; offset < maxOffset; offset++) { + QCOMPARE(search( +- testArray.cbegin(), testArray.cend(), offset, Direction::Forward, ++ testArray.cbegin(), testArray.cend(), offset, SearchDirection::Forward, + [](int num) { return num == 2; }, [] {}), + 1); + QCOMPARE(search( +- testArray.cbegin(), testArray.cend(), offset, Direction::Backward, ++ testArray.cbegin(), testArray.cend(), offset, SearchDirection::Backward, + [](int num) { return num == 2; }, [] {}), + 1); + } +@@ -51,7 +51,7 @@ private slots: + { + bool endReached = false; + QCOMPARE(search( +- testArray.cbegin(), testArray.cend(), 1, Direction::Forward, [](int i) { return i == 1; }, ++ testArray.cbegin(), testArray.cend(), 1, SearchDirection::Forward, [](int i) { return i == 1; }, + [&endReached] { endReached = true; }), + 0); + QCOMPARE(endReached, true); +@@ -60,7 +60,7 @@ private slots: + { + bool endReached = false; + QCOMPARE(search( +- testArray.cbegin(), testArray.cend(), 1, Direction::Backward, [](int i) { return i == 4; }, ++ testArray.cbegin(), testArray.cend(), 1, SearchDirection::Backward, [](int i) { return i == 4; }, + [&endReached] { endReached = true; }), + 3); + QCOMPARE(endReached, true); +@@ -73,7 +73,7 @@ private slots: + + for (int i = 0; i < 2; i++) { + QCOMPARE(search( +- testArray.cbegin(), testArray.cend(), 0, Direction::Forward, [](int) { return true; }, [] {}), ++ testArray.cbegin(), testArray.cend(), 0, SearchDirection::Forward, [](int) { return true; }, [] {}), + -1); + } + } +@@ -83,7 +83,7 @@ private slots: + const std::array testArray = {0}; + + QCOMPARE(search( +- testArray.cbegin(), testArray.cend(), 1, Direction::Forward, [](int i) { return i == 0; }, [] {}), ++ testArray.cbegin(), testArray.cend(), 1, SearchDirection::Forward, [](int i) { return i == 0; }, [] {}), + 0); + } + +@@ -93,7 +93,7 @@ private slots: + + for (std::size_t i = 0; i < testArray.size(); i++) { + QCOMPARE(search( +- testArray.cbegin() + 1, testArray.cbegin() + 3, i, Direction::Forward, ++ testArray.cbegin() + 1, testArray.cbegin() + 3, i, SearchDirection::Forward, + [](int i) { return i == 0; }, [] {}), + -1); + } diff --git a/dev-debug/hotspot/hotspot-1.5.1_p20250907.ebuild b/dev-debug/hotspot/hotspot-1.5.1_p20250907.ebuild new file mode 100644 index 000000000000..71467c563d7e --- /dev/null +++ b/dev-debug/hotspot/hotspot-1.5.1_p20250907.ebuild @@ -0,0 +1,124 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +QTMIN=6.8.1 +KFMIN=6.18.0 + +inherit ecm xdg + +DESCRIPTION="Linux perf GUI for performance analysis" +HOMEPAGE="https://github.com/KDAB/hotspot" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/KDAB/hotspot" + inherit git-r3 +elif [[ ${PV} == *_p* ]] ; then + HOTSPOT_COMMIT="b61451d827dd23e35c5f611e3626226a119dfa48" + PERFPARSER_COMMIT="65472541f74da213583535c8bb4fea831e875109" + PREFIXTICKLABELS_COMMIT="7cd6d5a04cf3747cc9327efdbcbf43620efaa0c1" + SRC_URI=" + https://github.com/KDAB/hotspot/archive/${HOTSPOT_COMMIT}.tar.gz -> ${PN}-${HOTSPOT_COMMIT}.gh.tar.gz + https://github.com/KDAB/perfparser/archive/${PERFPARSER_COMMIT}.tar.gz -> perfparser-${PERFPARSER_COMMIT}.gh.tar.gz + https://github.com/koenpoppe/PrefixTickLabels/archive/${PREFIXTICKLABELS_COMMIT}.tar.gz -> PrefixTickLabels-${PREFIXTICKLABELS_COMMIT}.gh.tar.gz + " + S="${WORKDIR}"/${PN}-${HOTSPOT_COMMIT} +else + SRC_URI=" + https://github.com/KDAB/hotspot/releases/download/v${PV}/${PN}-v${PV}.tar.gz + https://github.com/KDAB/hotspot/releases/download/v${PV}/${PN}-perfparser-v${PV}.tar.gz -> ${PN}-v${PV}-perfparser.tar.gz + https://github.com/KDAB/hotspot/releases/download/v${PV}/${PN}-PrefixTickLabels-v${PV}.tar.gz -> ${PN}-v${PV}-PrefixTickLabels.tar.gz + " + S="${WORKDIR}"/${PN} +fi + +# hotspot itself is GPL-2 or GPL-3 +# bundled perfparser is GPL-3 +# bundled PrefixTickLabels is GPL-3 +LICENSE="|| ( GPL-2 GPL-3 ) GPL-3" +SLOT="0" +IUSE="debuginfod" +if [[ ${PV} != 9999 ]] ; then + KEYWORDS="~amd64" +fi + +DEPEND=" + app-arch/zstd:= + dev-libs/elfutils[debuginfod?] + dev-libs/qcustomplot + >=dev-qt/qtbase-${QTMIN}:6=[network,widgets] + >=dev-qt/qtsvg-${QTMIN}:6 + gui-libs/kddockwidgets:= + >=kde-frameworks/karchive-${KFMIN}:6 + >=kde-frameworks/kconfigwidgets-${KFMIN}:6 + >=kde-frameworks/kcoreaddons-${KFMIN}:6 + >=kde-frameworks/ki18n-${KFMIN}:6 + >=kde-frameworks/kiconthemes-${KFMIN}:6 + >=kde-frameworks/kio-${KFMIN}:6 + >=kde-frameworks/kitemviews-${KFMIN}:6 + >=kde-frameworks/kitemmodels-${KFMIN}:6 + >=kde-frameworks/knotifications-${KFMIN}:6 + >=kde-frameworks/kparts-${KFMIN}:6 + >=kde-frameworks/kwindowsystem-${KFMIN}:6 + >=kde-frameworks/solid-${KFMIN}:6 + >=kde-frameworks/syntax-highlighting-${KFMIN}:6 + >=kde-frameworks/threadweaver-${KFMIN}:6 + media-gfx/kgraphviewer + sys-devel/gettext +" +RDEPEND=" + ${DEPEND} + dev-util/perf + sys-devel/binutils:* +" + +PATCHES=( + "${FILESDIR}"/${PN}-odr.patch +) + +src_unpack() { + if [[ ${PV} == 9999 ]] ; then + git-r3_src_unpack + elif [[ ${PV} == *_p* ]] ; then + unpack ${PN}-${HOTSPOT_COMMIT}.gh.tar.gz + tar -xf "${DISTDIR}"/perfparser-${PERFPARSER_COMMIT}.gh.tar.gz --strip-components=1 -C "${S}"/3rdparty/perfparser || die + tar -xf "${DISTDIR}"/PrefixTickLabels-${PREFIXTICKLABELS_COMMIT}.gh.tar.gz --strip-components=1 -C "${S}"/3rdparty/PrefixTickLabels || die + else + unpack ${PN}-v${PV}.tar.gz + tar -xf "${DISTDIR}"/${PN}-v${PV}-perfparser.tar.gz --strip-components=1 -C "${S}"/3rdparty/perfparser || die + tar -xf "${DISTDIR}"/${PN}-v${PV}-PrefixTickLabels.tar.gz --strip-components=1 -C "${S}"/3rdparty/PrefixTickLabels || die + fi +} + +src_prepare() { + if ! use debuginfod ; then + sed -i \ + '/target_link_libraries(libhotspot-perfparser PRIVATE ${LIBDEBUGINFOD_LIBRARIES})/d' \ + 3rdparty/perfparser.cmake || die "sed failed for perfparser" + + sed -i \ + '/target_compile_definitions(libhotspot-perfparser PRIVATE HAVE_DWFL_GET_DEBUGINFOD_CLIENT=1)/d' \ + 3rdparty/perfparser.cmake || die "sed failed for perfparser" + fi + + ecm_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DQT6_BUILD=true + ) + + ecm_src_configure +} + +src_test() { + CMAKE_SKIP_TESTS=( + # Complains about {d,rustc}_demangle missing, but may fail + # for other reasons too. + tst_perfparser + ) + + ecm_src_test +} diff --git a/dev-debug/hotspot/hotspot-9999.ebuild b/dev-debug/hotspot/hotspot-9999.ebuild new file mode 100644 index 000000000000..71467c563d7e --- /dev/null +++ b/dev-debug/hotspot/hotspot-9999.ebuild @@ -0,0 +1,124 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +QTMIN=6.8.1 +KFMIN=6.18.0 + +inherit ecm xdg + +DESCRIPTION="Linux perf GUI for performance analysis" +HOMEPAGE="https://github.com/KDAB/hotspot" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/KDAB/hotspot" + inherit git-r3 +elif [[ ${PV} == *_p* ]] ; then + HOTSPOT_COMMIT="b61451d827dd23e35c5f611e3626226a119dfa48" + PERFPARSER_COMMIT="65472541f74da213583535c8bb4fea831e875109" + PREFIXTICKLABELS_COMMIT="7cd6d5a04cf3747cc9327efdbcbf43620efaa0c1" + SRC_URI=" + https://github.com/KDAB/hotspot/archive/${HOTSPOT_COMMIT}.tar.gz -> ${PN}-${HOTSPOT_COMMIT}.gh.tar.gz + https://github.com/KDAB/perfparser/archive/${PERFPARSER_COMMIT}.tar.gz -> perfparser-${PERFPARSER_COMMIT}.gh.tar.gz + https://github.com/koenpoppe/PrefixTickLabels/archive/${PREFIXTICKLABELS_COMMIT}.tar.gz -> PrefixTickLabels-${PREFIXTICKLABELS_COMMIT}.gh.tar.gz + " + S="${WORKDIR}"/${PN}-${HOTSPOT_COMMIT} +else + SRC_URI=" + https://github.com/KDAB/hotspot/releases/download/v${PV}/${PN}-v${PV}.tar.gz + https://github.com/KDAB/hotspot/releases/download/v${PV}/${PN}-perfparser-v${PV}.tar.gz -> ${PN}-v${PV}-perfparser.tar.gz + https://github.com/KDAB/hotspot/releases/download/v${PV}/${PN}-PrefixTickLabels-v${PV}.tar.gz -> ${PN}-v${PV}-PrefixTickLabels.tar.gz + " + S="${WORKDIR}"/${PN} +fi + +# hotspot itself is GPL-2 or GPL-3 +# bundled perfparser is GPL-3 +# bundled PrefixTickLabels is GPL-3 +LICENSE="|| ( GPL-2 GPL-3 ) GPL-3" +SLOT="0" +IUSE="debuginfod" +if [[ ${PV} != 9999 ]] ; then + KEYWORDS="~amd64" +fi + +DEPEND=" + app-arch/zstd:= + dev-libs/elfutils[debuginfod?] + dev-libs/qcustomplot + >=dev-qt/qtbase-${QTMIN}:6=[network,widgets] + >=dev-qt/qtsvg-${QTMIN}:6 + gui-libs/kddockwidgets:= + >=kde-frameworks/karchive-${KFMIN}:6 + >=kde-frameworks/kconfigwidgets-${KFMIN}:6 + >=kde-frameworks/kcoreaddons-${KFMIN}:6 + >=kde-frameworks/ki18n-${KFMIN}:6 + >=kde-frameworks/kiconthemes-${KFMIN}:6 + >=kde-frameworks/kio-${KFMIN}:6 + >=kde-frameworks/kitemviews-${KFMIN}:6 + >=kde-frameworks/kitemmodels-${KFMIN}:6 + >=kde-frameworks/knotifications-${KFMIN}:6 + >=kde-frameworks/kparts-${KFMIN}:6 + >=kde-frameworks/kwindowsystem-${KFMIN}:6 + >=kde-frameworks/solid-${KFMIN}:6 + >=kde-frameworks/syntax-highlighting-${KFMIN}:6 + >=kde-frameworks/threadweaver-${KFMIN}:6 + media-gfx/kgraphviewer + sys-devel/gettext +" +RDEPEND=" + ${DEPEND} + dev-util/perf + sys-devel/binutils:* +" + +PATCHES=( + "${FILESDIR}"/${PN}-odr.patch +) + +src_unpack() { + if [[ ${PV} == 9999 ]] ; then + git-r3_src_unpack + elif [[ ${PV} == *_p* ]] ; then + unpack ${PN}-${HOTSPOT_COMMIT}.gh.tar.gz + tar -xf "${DISTDIR}"/perfparser-${PERFPARSER_COMMIT}.gh.tar.gz --strip-components=1 -C "${S}"/3rdparty/perfparser || die + tar -xf "${DISTDIR}"/PrefixTickLabels-${PREFIXTICKLABELS_COMMIT}.gh.tar.gz --strip-components=1 -C "${S}"/3rdparty/PrefixTickLabels || die + else + unpack ${PN}-v${PV}.tar.gz + tar -xf "${DISTDIR}"/${PN}-v${PV}-perfparser.tar.gz --strip-components=1 -C "${S}"/3rdparty/perfparser || die + tar -xf "${DISTDIR}"/${PN}-v${PV}-PrefixTickLabels.tar.gz --strip-components=1 -C "${S}"/3rdparty/PrefixTickLabels || die + fi +} + +src_prepare() { + if ! use debuginfod ; then + sed -i \ + '/target_link_libraries(libhotspot-perfparser PRIVATE ${LIBDEBUGINFOD_LIBRARIES})/d' \ + 3rdparty/perfparser.cmake || die "sed failed for perfparser" + + sed -i \ + '/target_compile_definitions(libhotspot-perfparser PRIVATE HAVE_DWFL_GET_DEBUGINFOD_CLIENT=1)/d' \ + 3rdparty/perfparser.cmake || die "sed failed for perfparser" + fi + + ecm_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DQT6_BUILD=true + ) + + ecm_src_configure +} + +src_test() { + CMAKE_SKIP_TESTS=( + # Complains about {d,rustc}_demangle missing, but may fail + # for other reasons too. + tst_perfparser + ) + + ecm_src_test +} diff --git a/dev-debug/hotspot/metadata.xml b/dev-debug/hotspot/metadata.xml new file mode 100644 index 000000000000..f27aa008d8d5 --- /dev/null +++ b/dev-debug/hotspot/metadata.xml @@ -0,0 +1,14 @@ + + + + + sam@gentoo.org + Sam James + + + Enable debuginfod support via dev-libs/elfutils libdebuginfod + + + KDAB/hotspot + +