summaryrefslogtreecommitdiff
path: root/kde-plasma/ksystemstats
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-08-16 21:30:25 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-08-16 21:30:25 +0100
commit2ef316f0ffbd90d833effd2d09d1232e5767e321 (patch)
treeb283d778349e3970cd176709bcc3bc4e401d9f17 /kde-plasma/ksystemstats
parenta109f15e80eca93b1cc39b6f7ddb12124dfe2ca7 (diff)
gentoo auto-resync : 16:08:2023 - 21:30:25
Diffstat (limited to 'kde-plasma/ksystemstats')
-rw-r--r--kde-plasma/ksystemstats/Manifest3
-rw-r--r--kde-plasma/ksystemstats/files/ksystemstats-5.27.6-nvidia-data-fields.patch131
-rw-r--r--kde-plasma/ksystemstats/ksystemstats-5.27.6-r1.ebuild48
3 files changed, 0 insertions, 182 deletions
diff --git a/kde-plasma/ksystemstats/Manifest b/kde-plasma/ksystemstats/Manifest
index 8ea2f8acd21f..f3bbd1fa7931 100644
--- a/kde-plasma/ksystemstats/Manifest
+++ b/kde-plasma/ksystemstats/Manifest
@@ -1,6 +1,3 @@
-AUX ksystemstats-5.27.6-nvidia-data-fields.patch 5633 BLAKE2B 2196a5d272c19c8a0d7ef1bb4841c6e1145d227520d98e27c173142ea7d10b5a5ee2a4e9387b8ca136b8cc83c6dca97b5d13442caa3d7dc2524edaeac2cdb588 SHA512 33d4802e51bacc28347d502a18c006c3850419d4b770af580ed95d3826131d34229438d3b30e0f76173bb5519029e51680d1946e8bb5da9d35f721d482419ca4
-DIST ksystemstats-5.27.6.tar.xz 116232 BLAKE2B 1b9ef600ac13b9e925d12a9c936fbf06b106c5e203ea1c17da511a9611171a833135d62eedfa2c279c5af25ba920a7b3ca480038d0ebe69b78008de701bf5216 SHA512 1ecaffa1642d8761993606be938efd183dc0de39f8d15cb19fc96871fe6d5de03628e0bf5cffe59bdb32283f66890a7783de04ebc7da4960e3f90104f15bd5ba
DIST ksystemstats-5.27.7.tar.xz 116584 BLAKE2B bed1e8652ab91211a5f7a2a31d74fe685fdd915e89feb8e5b6a6b7743e942fe1f7d0102ce27abdc0e028396dc851d622fb250c194b14699e9f2f7cc1c86e6d73 SHA512 58dc0e61294ef23d1e4feb430872f47bb90e544cc12163dba917e8bcce5b9aa1248347203488c530eb56a56d41a3631ba3c971edda5b17ed3e74cddd81083625
-EBUILD ksystemstats-5.27.6-r1.ebuild 1169 BLAKE2B 55db81ccb67283ac29829b04da1bca832381f4639c44ba556ae5666e68f628f58f1733303077db651e219f6cec17bd65e58d035c30e0b790b2d43bb7a6d60e1c SHA512 160576de06647b604c592357789894a0d047cc301702f2f9322fcb5ffcdc8707fa6deb14e2ca5370a019c770e6e6c2f85096093f3497abec994597e5619d8319
EBUILD ksystemstats-5.27.7.ebuild 1095 BLAKE2B 9e66afac6bfbfa25ec6ac20995273d8b340f4fcfeff8bde61a6ece39e8f315698fc10f48b61a7614b44c1be08f81ad59ac4df193c59562ffbf9b6ca644fc5566 SHA512 efe80c58b29d8f261d9ca44973c1e0594fdfda114573ce1fc996fe762bc90d1938b65db9de6c405ba6ef8e430b8f12b23b1e648107f17f119ee28f7ba4ad197b
MISC metadata.xml 467 BLAKE2B 61ac6047a4cb3d54d26f963b75c94022a501fd1b1b9ee227cce16023fb40b101ba40c6ff99e02c5913137b191bd9c516249387b0310f6558c9800b10f52e780a SHA512 0ad261d9d2e7a45d01b06a15270346bf169a3a8d827b409616e3801e4357910fe196813dd87ff4bea34e61cce3931443d9b617ef532230448f54048d1ed84f4a
diff --git a/kde-plasma/ksystemstats/files/ksystemstats-5.27.6-nvidia-data-fields.patch b/kde-plasma/ksystemstats/files/ksystemstats-5.27.6-nvidia-data-fields.patch
deleted file mode 100644
index 718bbd8c64e2..000000000000
--- a/kde-plasma/ksystemstats/files/ksystemstats-5.27.6-nvidia-data-fields.patch
+++ /dev/null
@@ -1,131 +0,0 @@
-From 4f7213e6e742b993feeaf300181a67923e60c0f4 Mon Sep 17 00:00:00 2001
-From: David Redondo <kde@david-redondo.de>
-Date: Wed, 10 May 2023 02:26:29 +0000
-Subject: [PATCH] gpu/nvidia: Discover data fields based on headers
-
-This guards us against the appearance of new fields or if they
-ever appear in a different order.
-BUG:470474
-FIXED-IN:5.27.7
-
-(cherry picked from commit 7f9ead6bddfdf6f13a1ea48791f8f5d5c80c6980)
-Because in Qt5 QVector<T>::indexOf only takes T's we have to provide
-our own indexOf here.
----
- plugins/gpu/NvidiaSmiProcess.cpp | 56 ++++++++++++++++++++++----------
- plugins/gpu/NvidiaSmiProcess.h | 14 ++++++++
- 2 files changed, 53 insertions(+), 17 deletions(-)
-
-diff --git a/plugins/gpu/NvidiaSmiProcess.cpp b/plugins/gpu/NvidiaSmiProcess.cpp
-index 7f8dd62..d92b396 100644
---- a/plugins/gpu/NvidiaSmiProcess.cpp
-+++ b/plugins/gpu/NvidiaSmiProcess.cpp
-@@ -155,19 +155,37 @@ void NvidiaSmiProcess::unref()
- void NvidiaSmiProcess::readStatisticsData()
- {
- while (m_process->canReadLine()) {
-- const QString line = m_process->readLine();
-- if (line.startsWith(QLatin1Char('#'))) {
-- continue;
-- }
-+ QString line = m_process->readLine();
- #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
-- const QVector<QStringRef> parts = QStringRef(&line).trimmed().split(QLatin1Char(' '), Qt::SkipEmptyParts);
-+ QVector<QStringRef> parts = QStringRef(&line).trimmed().split(QLatin1Char(' '), Qt::SkipEmptyParts);
- #else
-- const QVector<QStringView> parts = QStringView(line).trimmed().split(QLatin1Char(' '), Qt::SkipEmptyParts);
-+ QVector<QStringView> parts = QStringView(line).trimmed().split(QLatin1Char(' '), Qt::SkipEmptyParts);
- #endif
--
-- // format at time of writing is
-- // # gpu pwr gtemp mtemp sm mem enc dec mclk pclk fb bar1
-- if (parts.count() != 12) {
-+ // Because in Qt5 indexOf of QVector<T> only takes T's, write our own indexOf taking arbitrary types
-+ auto indexOf = [](const auto &stack, const auto& needle) {
-+ auto it = std::find(stack.cbegin(), stack.cend(), needle);
-+ return it != stack.cend() ? std::distance(stack.cbegin(), it) : -1;
-+ };
-+
-+ // discover index of fields in the header format is something like
-+ //# gpu pwr gtemp mtemp sm mem enc dec mclk pclk fb bar1
-+ // # Idx W C C % % % % MHz MHz MB MB
-+ // 0 25 29 - 1 1 0 0 4006 1506 891 22
-+ if (line.startsWith(QLatin1Char('#'))) {
-+ if (m_dmonIndices.gpu == -1) {
-+ // Remove First part because of leading '# ';
-+ parts.removeFirst();
-+ m_dmonIndices.gpu = indexOf(parts, QLatin1String("gpu"));
-+ m_dmonIndices.power = indexOf(parts, QLatin1String("pwr"));
-+ m_dmonIndices.gtemp = indexOf(parts, QLatin1String("gtemp"));
-+ m_dmonIndices.sm = indexOf(parts, QLatin1String("sm"));
-+ m_dmonIndices.enc = indexOf(parts, QLatin1String("enc"));
-+ m_dmonIndices.dec = indexOf(parts, QLatin1String("dec"));
-+ m_dmonIndices.fb = indexOf(parts, QLatin1String("fb"));
-+ m_dmonIndices.bar1 = indexOf(parts, QLatin1String("bar1"));
-+ m_dmonIndices.mclk = indexOf(parts, QLatin1String("mclk"));
-+ m_dmonIndices.pclk = indexOf(parts, QLatin1String("pclk"));
-+ }
- continue;
- }
-
-@@ -177,19 +195,23 @@ void NvidiaSmiProcess::readStatisticsData()
- continue;
- }
-
-+ auto readDataIfFound = [&parts, this] (int index) {
-+ return index > 0 ? parts[index].toUInt() : 0;
-+ };
-+
- GpuData data;
-- data.index = index;
-- data.power = parts[1].toUInt();
-- data.temperature = parts[2].toUInt();
-+ data.index = readDataIfFound(m_dmonIndices.gpu);
-+ data.power = readDataIfFound(m_dmonIndices.power);
-+ data.temperature = readDataIfFound(m_dmonIndices.gtemp);
-
- // GPU usage equals "SM" usage + "ENC" usage + "DEC" usage
-- data.usage = parts[4].toUInt() + parts[6].toUInt() + parts[7].toUInt();
-+ data.usage = readDataIfFound(m_dmonIndices.sm) + readDataIfFound(m_dmonIndices.enc) + readDataIfFound(m_dmonIndices.dec);
-
- // Total memory used equals "FB" usage + "BAR1" usage
-- data.memoryUsed = parts[10].toUInt() + parts[11].toUInt();
-+ data.memoryUsed = readDataIfFound(m_dmonIndices.fb) + readDataIfFound(m_dmonIndices.bar1);
-
-- data.memoryFrequency = parts[8].toUInt();
-- data.coreFrequency = parts[9].toUInt();
-+ data.memoryFrequency = readDataIfFound(m_dmonIndices.mclk);
-+ data.coreFrequency = readDataIfFound(m_dmonIndices.pclk);
-
- Q_EMIT dataReceived(data);
- }
-diff --git a/plugins/gpu/NvidiaSmiProcess.h b/plugins/gpu/NvidiaSmiProcess.h
-index f39cc9d..2cd8504 100644
---- a/plugins/gpu/NvidiaSmiProcess.h
-+++ b/plugins/gpu/NvidiaSmiProcess.h
-@@ -49,8 +49,22 @@ public:
- private:
- void readStatisticsData();
-
-+ struct dmonIndices {
-+ int gpu = -1;
-+ int gtemp = -1;
-+ int power = -1;
-+ int sm = -1;
-+ int enc = -1;
-+ int dec = -1;
-+ int fb = -1;
-+ int bar1 = -1;
-+ int mclk = -1;
-+ int pclk = -1;
-+ };
-+
- QString m_smiPath;
- std::vector<GpuQueryResult> m_queryResult;
- std::unique_ptr<QProcess> m_process = nullptr;
- int m_references = 0;
-+ dmonIndices m_dmonIndices;
- };
---
-GitLab
-
diff --git a/kde-plasma/ksystemstats/ksystemstats-5.27.6-r1.ebuild b/kde-plasma/ksystemstats/ksystemstats-5.27.6-r1.ebuild
deleted file mode 100644
index d300cb176686..000000000000
--- a/kde-plasma/ksystemstats/ksystemstats-5.27.6-r1.ebuild
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-ECM_HANDBOOK="forceoptional"
-ECM_TEST="forceoptional"
-KFMIN=5.106.0
-PVCUT=$(ver_cut 1-3)
-QTMIN=5.15.9
-VIRTUALX_REQUIRED="test" # bug 909312 (test fails)
-inherit ecm plasma.kde.org virtualx
-
-DESCRIPTION="Plugin-based system monitoring daemon"
-
-LICENSE="GPL-2+"
-SLOT="5"
-KEYWORDS="amd64 ~arm arm64 ~loong ~ppc64 ~riscv x86"
-IUSE="networkmanager"
-
-DEPEND="
- dev-libs/libnl:3
- >=dev-qt/qtdbus-${QTMIN}:5
- >=dev-qt/qtnetwork-${QTMIN}:5
- >=kde-frameworks/kcoreaddons-${KFMIN}:5
- >=kde-frameworks/kdbusaddons-${KFMIN}:5
- >=kde-frameworks/ki18n-${KFMIN}:5
- >=kde-frameworks/kio-${KFMIN}:5
- >=kde-frameworks/solid-${KFMIN}:5
- >=kde-plasma/libksysguard-${PVCUT}:5
- net-libs/libpcap
- sys-apps/lm-sensors:=
- sys-libs/libcap
- virtual/libudev:=
- networkmanager? ( >=kde-frameworks/networkmanager-qt-${KFMIN}:5 )
-"
-RDEPEND="${DEPEND}
- !<kde-plasma/ksysguard-5.21.90:5
-"
-
-PATCHES=( "${FILESDIR}/${P}-nvidia-data-fields.patch" ) # KDE-bug 470474
-
-src_configure() {
- local mycmakeargs=(
- $(cmake_use_find_package networkmanager KF5NetworkManagerQt)
- )
- ecm_src_configure
-}