pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/x11/deforaos-panel
Module Name: pkgsrc
Committed By: bouyer
Date: Thu Apr 12 16:09:50 UTC 2018
Modified Files:
pkgsrc/x11/deforaos-panel: Makefile distinfo
Added Files:
pkgsrc/x11/deforaos-panel/patches: patch-src_applets_cpufreq.c
Log Message:
Also est machdep.cpu.frequency, which is the sysctl's name on recent NetBSD
on arm.
While there also check that the frequency changed before updating the
gtk_label this makes the panel use much less CPU time.
OK khorben@
To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 pkgsrc/x11/deforaos-panel/Makefile
cvs rdiff -u -r1.13 -r1.14 pkgsrc/x11/deforaos-panel/distinfo
cvs rdiff -u -r0 -r1.1 \
pkgsrc/x11/deforaos-panel/patches/patch-src_applets_cpufreq.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/x11/deforaos-panel/Makefile
diff -u pkgsrc/x11/deforaos-panel/Makefile:1.29 pkgsrc/x11/deforaos-panel/Makefile:1.30
--- pkgsrc/x11/deforaos-panel/Makefile:1.29 Mon Mar 12 11:15:49 2018
+++ pkgsrc/x11/deforaos-panel/Makefile Thu Apr 12 16:09:50 2018
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.29 2018/03/12 11:15:49 wiz Exp $
+# $NetBSD: Makefile,v 1.30 2018/04/12 16:09:50 bouyer Exp $
#
DISTNAME= Panel-0.3.6
PKGNAME= deforaos-panel-0.3.6
-PKGREVISION= 5
+PKGREVISION= 6
CATEGORIES= x11
MASTER_SITES= https://www.defora.org/os/download/download/4417/
Index: pkgsrc/x11/deforaos-panel/distinfo
diff -u pkgsrc/x11/deforaos-panel/distinfo:1.13 pkgsrc/x11/deforaos-panel/distinfo:1.14
--- pkgsrc/x11/deforaos-panel/distinfo:1.13 Sat Feb 20 00:46:55 2016
+++ pkgsrc/x11/deforaos-panel/distinfo Thu Apr 12 16:09:50 2018
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.13 2016/02/20 00:46:55 khorben Exp $
+$NetBSD: distinfo,v 1.14 2018/04/12 16:09:50 bouyer Exp $
SHA1 (Panel-0.3.6.tar.gz) = a87f49c638a2d8df210c21bd684b3fbdc01a375a
RMD160 (Panel-0.3.6.tar.gz) = 31a25b60c60b0198352b3fa2f26ee4f59418620d
SHA512 (Panel-0.3.6.tar.gz) = cafdeb2e9127520dd65f1cef5e24dadac063146868517173771e8d44eb742687d9d79fa2738086008628c9cadfa39188cc0eb5624bd5efafbc00556e1b58c487
Size (Panel-0.3.6.tar.gz) = 146129 bytes
+SHA1 (patch-src_applets_cpufreq.c) = 76b1fbd3ba6f72b0cd2cc0ef7ad324e98bb29cc3
Added files:
Index: pkgsrc/x11/deforaos-panel/patches/patch-src_applets_cpufreq.c
diff -u /dev/null pkgsrc/x11/deforaos-panel/patches/patch-src_applets_cpufreq.c:1.1
--- /dev/null Thu Apr 12 16:09:50 2018
+++ pkgsrc/x11/deforaos-panel/patches/patch-src_applets_cpufreq.c Thu Apr 12 16:09:50 2018
@@ -0,0 +1,42 @@
+$NetBSD: patch-src_applets_cpufreq.c,v 1.1 2018/04/12 16:09:50 bouyer Exp $
+Fix systctl name on newer NetBSD
+Avoid updating display when not needed.
+
+--- src/applets/cpufreq.c.orig 2016-01-12 02:32:16.000000000 +0100
++++ src/applets/cpufreq.c 2018-04-10 19:27:01.584667727 +0200
+@@ -43,6 +43,7 @@
+ int min;
+ int max;
+ int step;
++ int actual;
+ #if defined(__FreeBSD__) || defined(__NetBSD__)
+ char const * name;
+ #endif
+@@ -101,6 +102,9 @@
+ else if(sysctlbyname("machdep.frequency.available", &freq, &freqsize,
+ NULL, 0) == 0)
+ p = "machdep.frequency.current";
++ else if(sysctlbyname("machdep.cpu.frequency.available", &freq, &freqsize,
++ NULL, 0) == 0)
++ p = "machdep.cpu.frequency.current";
+ else
+ {
+ error_set("%s: %s", applet.name, _("No support detected"));
+@@ -125,6 +129,7 @@
+ gtk_box_pack_start(GTK_BOX(cpufreq->hbox), image, FALSE, TRUE, 0);
+ cpufreq->min = 0;
+ cpufreq->max = 0;
++ cpufreq->actual = 0;
+ cpufreq->step = 1;
+ cpufreq->name = p;
+ cpufreq->max = atoi(freq);
+@@ -181,6 +186,9 @@
+ helper->error(NULL, error_get(NULL), 1);
+ return TRUE;
+ }
++ if (freq == cpufreq->actual)
++ return TRUE;
++ cpufreq->actual = freq;
+ snprintf(buf, sizeof(buf), "%4u", (unsigned int)freq);
+ gtk_label_set_text(GTK_LABEL(cpufreq->label), buf);
+ # if GTK_CHECK_VERSION(2, 12, 0)
Home |
Main Index |
Thread Index |
Old Index