public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: kde-plasma/libksysguard/files/, kde-plasma/libksysguard/
Date: Wed, 25 May 2022 21:13:14 +0000 (UTC)	[thread overview]
Message-ID: <1653513009.dbcebe7e36a1dbcf4215599ac69e93322383a641.asturm@gentoo> (raw)

commit:     dbcebe7e36a1dbcf4215599ac69e93322383a641
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed May 25 19:28:10 2022 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed May 25 21:10:09 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dbcebe7e

kde-plasma/libksysguard: Backport several 5.24.6 fixes

Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...bksysguard-5.24.5-fix-missing-gpu-sensors.patch | 32 +++++++++
 ...ard-5.24.5-fix-missing-selfmade-presets-1.patch | 35 ++++++++++
 ...ard-5.24.5-fix-missing-selfmade-presets-2.patch | 43 ++++++++++++
 .../libksysguard/libksysguard-5.24.5-r1.ebuild     | 80 ++++++++++++++++++++++
 4 files changed, 190 insertions(+)

diff --git a/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-gpu-sensors.patch b/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-gpu-sensors.patch
new file mode 100644
index 000000000000..bf81b8bf68eb
--- /dev/null
+++ b/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-gpu-sensors.patch
@@ -0,0 +1,32 @@
+From 88722b18c92f3a688a69abef9022cbcdcb5163bb Mon Sep 17 00:00:00 2001
+From: David Redondo <kde@david-redondo.de>
+Date: Fri, 29 Apr 2022 13:59:38 +0200
+Subject: [PATCH] Fall back to power average if input is not available
+
+Some power sensors don't expose a current value most notably amdgpu.
+For those fall back to the average reading if available.
+BUG:445920
+
+
+(cherry picked from commit 7758d202eed28169c031e099e408ea258469e408)
+---
+ systemstats/SensorsFeatureSensor.cpp | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/systemstats/SensorsFeatureSensor.cpp b/systemstats/SensorsFeatureSensor.cpp
+index 6c8bdb34..3555115f 100644
+--- a/systemstats/SensorsFeatureSensor.cpp
++++ b/systemstats/SensorsFeatureSensor.cpp
+@@ -95,6 +95,9 @@ makeSensorsFeatureSensor(const QString &id, const sensors_chip_name *const chipN
+         break;
+     case SENSORS_FEATURE_POWER:
+         valueFeature = sensors_get_subfeature(chipName, feature, SENSORS_SUBFEATURE_POWER_INPUT);
++        if (!valueFeature) {
++            valueFeature = sensors_get_subfeature(chipName, feature, SENSORS_SUBFEATURE_POWER_AVERAGE);
++        }
+         unit = UnitWatt;
+         maximum = getValueOfFirstExisting({SENSORS_SUBFEATURE_POWER_CRIT, SENSORS_SUBFEATURE_POWER_MAX});
+         break;
+-- 
+GitLab
+

diff --git a/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-selfmade-presets-1.patch b/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-selfmade-presets-1.patch
new file mode 100644
index 000000000000..61b981734fa7
--- /dev/null
+++ b/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-selfmade-presets-1.patch
@@ -0,0 +1,35 @@
+From b94b0e11f9c0f718f109f37dad8a889301f3a59a Mon Sep 17 00:00:00 2001
+From: Arjen Hiemstra <ahiemstra@heimr.nl>
+Date: Mon, 9 May 2022 19:05:06 +0200
+Subject: [PATCH] Faces: Write preset faceproperties to the right location
+
+When loading presets we expect the faceproperties file to be located in
+"contents/config/" but when writing we are placing it in "contents/"
+which means that custom presets are not loaded properly.
+
+BUG: 450745
+
+
+(cherry picked from commit 05866a594198d8c76814d8cd4eb3e83cc9123c8d)
+---
+ faces/SensorFaceController.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/faces/SensorFaceController.cpp b/faces/SensorFaceController.cpp
+index d3daa87d..21fb2954 100644
+--- a/faces/SensorFaceController.cpp
++++ b/faces/SensorFaceController.cpp
+@@ -938,8 +938,8 @@ void SensorFaceController::savePreset()
+     cg.sync();
+ 
+     QDir subDir(dir.path());
+-    subDir.mkdir(QStringLiteral("contents"));
+-    KConfig faceConfig(subDir.path() % QStringLiteral("/contents/faceproperties"));
++    subDir.mkpath(QStringLiteral("contents/config"));
++    KConfig faceConfig(subDir.path() % QStringLiteral("/contents/config/faceproperties"));
+ 
+     KConfigGroup configGroup(&faceConfig, "Config");
+     configGroup.writeEntry(QStringLiteral("totalSensors"), QJsonDocument(totalSensors()).toJson(QJsonDocument::Compact));
+-- 
+GitLab
+

diff --git a/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-selfmade-presets-2.patch b/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-selfmade-presets-2.patch
new file mode 100644
index 000000000000..35bf11ee6431
--- /dev/null
+++ b/kde-plasma/libksysguard/files/libksysguard-5.24.5-fix-missing-selfmade-presets-2.patch
@@ -0,0 +1,43 @@
+From 0d06f3fdda71e87d70a4ca8d45af6badb3ab4ee1 Mon Sep 17 00:00:00 2001
+From: Arjen Hiemstra <ahiemstra@heimr.nl>
+Date: Mon, 9 May 2022 19:08:10 +0200
+Subject: [PATCH] Faces: Do not write resolved sensors to preset file
+
+The three sensor properties of FaceController contain the resolved
+sensors. This means we are not writing group regular expressions to face
+presets but are wiriting only the local sensors that were found for that
+group, pretty much bypassing why we have the groups in the first place.
+The unresolved sensors are only contained in the sensor configuration,
+so read them from there and write that to the preset faceproperties.
+
+
+(cherry picked from commit 1ea0671de11ea51aa2e181deafb70d8da588a2af)
+---
+ faces/SensorFaceController.cpp | 11 ++++++++---
+ 1 file changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/faces/SensorFaceController.cpp b/faces/SensorFaceController.cpp
+index 21fb2954..632b7dd4 100644
+--- a/faces/SensorFaceController.cpp
++++ b/faces/SensorFaceController.cpp
+@@ -942,9 +942,14 @@ void SensorFaceController::savePreset()
+     KConfig faceConfig(subDir.path() % QStringLiteral("/contents/config/faceproperties"));
+ 
+     KConfigGroup configGroup(&faceConfig, "Config");
+-    configGroup.writeEntry(QStringLiteral("totalSensors"), QJsonDocument(totalSensors()).toJson(QJsonDocument::Compact));
+-    configGroup.writeEntry(QStringLiteral("highPrioritySensorIds"), QJsonDocument(highPrioritySensorIds()).toJson(QJsonDocument::Compact));
+-    configGroup.writeEntry(QStringLiteral("lowPrioritySensorIds"), QJsonDocument(lowPrioritySensorIds()).toJson(QJsonDocument::Compact));
++
++    auto sensors = d->readAndUpdateSensors(d->sensorsGroup, QStringLiteral("totalSensors"));
++    configGroup.writeEntry(QStringLiteral("totalSensors"), QJsonDocument(sensors).toJson(QJsonDocument::Compact));
++    sensors = d->readAndUpdateSensors(d->sensorsGroup, QStringLiteral("highPrioritySensorIds"));
++    configGroup.writeEntry(QStringLiteral("highPrioritySensorIds"), QJsonDocument(sensors).toJson(QJsonDocument::Compact));
++    sensors = d->readAndUpdateSensors(d->sensorsGroup, QStringLiteral("lowPrioritySensorIds"));
++    configGroup.writeEntry(QStringLiteral("lowPrioritySensorIds"), QJsonDocument(sensors).toJson(QJsonDocument::Compact));
++    configGroup.writeEntry(QStringLiteral("chartFace"), faceId());
+ 
+     KConfigGroup colorsGroup(&faceConfig, "SensorColors");
+     d->colorsGroup.copyTo(&colorsGroup);
+-- 
+GitLab
+

diff --git a/kde-plasma/libksysguard/libksysguard-5.24.5-r1.ebuild b/kde-plasma/libksysguard/libksysguard-5.24.5-r1.ebuild
new file mode 100644
index 000000000000..5e70bb4448e2
--- /dev/null
+++ b/kde-plasma/libksysguard/libksysguard-5.24.5-r1.ebuild
@@ -0,0 +1,80 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+ECM_DESIGNERPLUGIN="true"
+ECM_TEST="true"
+KFMIN=5.90.0
+QTMIN=5.15.2
+VIRTUALX_REQUIRED="test"
+inherit ecm kde.org
+
+DESCRIPTION="Task management and system monitoring library"
+
+LICENSE="LGPL-2+"
+SLOT="5/9"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~riscv ~x86"
+IUSE="webengine X"
+
+COMMON_DEPEND="
+	dev-libs/libnl:3
+	>=dev-qt/qtdbus-${QTMIN}:5
+	>=dev-qt/qtdeclarative-${QTMIN}:5
+	>=dev-qt/qtgui-${QTMIN}:5
+	>=dev-qt/qtnetwork-${QTMIN}:5
+	>=dev-qt/qtwidgets-${QTMIN}:5
+	>=kde-frameworks/kauth-${KFMIN}:5
+	>=kde-frameworks/kcompletion-${KFMIN}:5
+	>=kde-frameworks/kconfig-${KFMIN}:5
+	>=kde-frameworks/kconfigwidgets-${KFMIN}:5
+	>=kde-frameworks/kcoreaddons-${KFMIN}:5
+	>=kde-frameworks/kdeclarative-${KFMIN}:5
+	>=kde-frameworks/ki18n-${KFMIN}:5
+	>=kde-frameworks/kjobwidgets-${KFMIN}:5
+	>=kde-frameworks/knewstuff-${KFMIN}:5
+	>=kde-frameworks/kpackage-${KFMIN}:5
+	>=kde-frameworks/kwidgetsaddons-${KFMIN}:5
+	>=kde-frameworks/kwindowsystem-${KFMIN}:5
+	net-libs/libpcap
+	sys-apps/lm-sensors:=
+	sys-libs/libcap
+	sys-libs/zlib
+	webengine? (
+		>=dev-qt/qtwebchannel-${QTMIN}:5
+		>=dev-qt/qtwebengine-${QTMIN}:5
+	)
+	X? (
+		>=dev-qt/qtx11extras-${QTMIN}:5
+		x11-libs/libX11
+		x11-libs/libXres
+	)
+"
+DEPEND="${COMMON_DEPEND}
+	>=kde-frameworks/kiconthemes-${KFMIN}:5
+	X? ( x11-base/xorg-proto )
+"
+RDEPEND="${COMMON_DEPEND}
+	!<kde-plasma/ksysguard-5.21.90:5
+	!<kde-plasma/plasma-workspace-5.18.80:5
+"
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-5.22.80-no-detailed-mem-message.patch
+	"${FILESDIR}"/${P}-fix-missing-gpu-sensors.patch # KDE-bug 445920
+	"${FILESDIR}"/${P}-fix-missing-selfmade-presets-{1,2}.patch # KDE-bug 450745
+)
+
+src_configure() {
+	local mycmakeargs=(
+		$(cmake_use_find_package webengine Qt5WebChannel)
+		$(cmake_use_find_package webengine Qt5WebEngineWidgets)
+		$(cmake_use_find_package X X11)
+	)
+
+	ecm_src_configure
+}
+
+src_test() {
+	LC_NUMERIC="C" ecm_src_test # bug 695514
+}


             reply	other threads:[~2022-05-25 21:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-25 21:13 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-09-19 15:27 [gentoo-commits] repo/gentoo:master commit in: kde-plasma/libksysguard/files/, kde-plasma/libksysguard/ Andreas Sturmlechner
2021-09-16 11:14 Andreas Sturmlechner
2021-09-14  9:04 Andreas Sturmlechner
2017-08-07  6:26 Andreas Sturmlechner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1653513009.dbcebe7e36a1dbcf4215599ac69e93322383a641.asturm@gentoo \
    --to=asturm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox