Friday, June 07, 2024

Control battery charging support in x11/kde-plasma/powerdevil

Please find below a simple patch to add control battery charging support
in powerdevil aka KDE Plamsa - systemsettings via sysctl(2).

I would be happy if someone would take a look at the code.

Rafael

Index: Makefile
===================================================================
RCS file: /cvs/ports/x11/kde-plasma/powerdevil/Makefile,v
diff -u -p -r1.4 Makefile
--- Makefile 20 May 2024 06:39:26 -0000 1.4
+++ Makefile 7 Jun 2024 09:16:00 -0000
@@ -1,5 +1,6 @@
COMMENT = power management daemon
DISTNAME = powerdevil-${VERSION}
+REVISION = 0

WANTLIB += ${COMPILER_LIBCXX} GL KF6AuthCore KF6ColorScheme KF6Completion
WANTLIB += KF6ConfigCore KF6ConfigGui KF6ConfigWidgets KF6CoreAddons
Index: patches/patch-daemon_chargethresholdhelper_cpp
===================================================================
RCS file: patches/patch-daemon_chargethresholdhelper_cpp
diff -N patches/patch-daemon_chargethresholdhelper_cpp
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-daemon_chargethresholdhelper_cpp 7 Jun 2024 09:16:00 -0000
@@ -0,0 +1,113 @@
+Index: daemon/chargethresholdhelper.cpp
+--- daemon/chargethresholdhelper.cpp.orig
++++ daemon/chargethresholdhelper.cpp
+@@ -8,6 +8,11 @@
+
+ #include <powerdevil_debug.h>
+
++#if defined(__OpenBSD__)
++ #include <sys/types.h>
++ #include <sys/sysctl.h>
++

No comments:

Post a Comment