From 4657d2a9a561059787735c31913eafa1b23869d0 Mon Sep 17 00:00:00 2001 From: jmmv Date: Sun, 9 Mar 2003 09:55:45 +0000 Subject: Update to 1.0.1. Changes since 0.9.0: * src/cpu_freebsd.c: changed to use instead of in the case of __FreeBSD_version >= 500101. (Thanks to Philip Paeps ) * main.c: changed description for `--cpu' oprion to be more clear. * README: updated * cpu_irix.c: added for IRIX (Jonathan C. Patschke ) * version 1.0.0 released * code cleanup/review * dockapp.c: renamed dockapp_getcolor() to dockapp_getcolor_pixel(). * dockapp.c: added get_closest_color_pixel() to find closest color in Pseudo visual class. * src/Makefile.am: added missing @DFLAGS@ * cpu_bsdi.c: added (Nicolas Belan ) * dockapp.c, dockapp.h: moved to libdockapp/dockapp.[ch] * libdockapp/{COPYING,AUTHORS}: added (taken from libdockapp-0.4.0) * configure.ac: removed '-L/usr/local/lib' '-I/usr/local/include' from *_search_path (Thanks to Thomas Runge ) * README: added 'for GNOME users' section * cpu_cywin.c: rewrote to separate cpu_get_usage(). ( ==> cpu_get_usage_9x(), cpu_get_usage_NT()) * dockapp.c: removed background panel from windowed mode. * dockapp.c: added '-wp, --windowed-withpanel' option. * main.c: added '-t, --title' option to specify title name (Thanks to Ryan Lovett ) * wmcpuload.1: updated * cpu_netbsd.c: added 'CP_INTR' parameter * added NetBSD support (Thomas Runge ) Closes PR pkg/20631 by Thomas Runge (the maintainer). --- sysutils/wmcpuload/Makefile | 7 ++-- sysutils/wmcpuload/distinfo | 9 ++--- sysutils/wmcpuload/patches/patch-aa | 26 -------------- sysutils/wmcpuload/patches/patch-ab | 12 ------- sysutils/wmcpuload/patches/patch-ac | 67 ------------------------------------- 5 files changed, 7 insertions(+), 114 deletions(-) delete mode 100644 sysutils/wmcpuload/patches/patch-aa delete mode 100644 sysutils/wmcpuload/patches/patch-ab delete mode 100644 sysutils/wmcpuload/patches/patch-ac (limited to 'sysutils/wmcpuload') diff --git a/sysutils/wmcpuload/Makefile b/sysutils/wmcpuload/Makefile index 4d3c4386eb5..0e74abaeb6d 100644 --- a/sysutils/wmcpuload/Makefile +++ b/sysutils/wmcpuload/Makefile @@ -1,12 +1,13 @@ -# $NetBSD: Makefile,v 1.2 2002/08/25 21:51:10 jlam Exp $ +# $NetBSD: Makefile,v 1.3 2003/03/09 09:55:45 jmmv Exp $ # -DISTNAME= wmcpuload-0.9.0 +DISTNAME= wmcpuload-1.0.1 CATEGORIES= sysutils MASTER_SITES= http://www.sh.rim.or.jp/~ssato/src/ +EXTRACT_SUFX= .tar.bz2 MAINTAINER= coto@core.de -HOMEPAGE= http://www.sh.rim.or.jp/~ssato/dockapp/index.shtml +HOMEPAGE= http://www.sh.rim.or.jp/~ssato/dockapp/\#wmcpuload COMMENT= dockable CPU monitor GNU_CONFIGURE= YES diff --git a/sysutils/wmcpuload/distinfo b/sysutils/wmcpuload/distinfo index 63dcf1edd7b..9b3107b5aa9 100644 --- a/sysutils/wmcpuload/distinfo +++ b/sysutils/wmcpuload/distinfo @@ -1,7 +1,4 @@ -$NetBSD: distinfo,v 1.1.1.1 2002/03/24 18:04:57 wiz Exp $ +$NetBSD: distinfo,v 1.2 2003/03/09 09:55:45 jmmv Exp $ -SHA1 (wmcpuload-0.9.0.tar.gz) = 5883ebcc2f3c11f1ef498a6740a1edb3c52ea816 -Size (wmcpuload-0.9.0.tar.gz) = 99481 bytes -SHA1 (patch-aa) = 4844c1927eb72d5f0599d6a26a040023d2845feb -SHA1 (patch-ab) = 42e9fabebfe23120d70ddff8b3e1b5bfd322fbbb -SHA1 (patch-ac) = cbedd3d888a1fdf70fdd03621f917949cf5c037c +SHA1 (wmcpuload-1.0.1.tar.bz2) = 6e767dd5acd291cfe3fc4fece5ff32eef78915e4 +Size (wmcpuload-1.0.1.tar.bz2) = 92457 bytes diff --git a/sysutils/wmcpuload/patches/patch-aa b/sysutils/wmcpuload/patches/patch-aa deleted file mode 100644 index 281a666ec7c..00000000000 --- a/sysutils/wmcpuload/patches/patch-aa +++ /dev/null @@ -1,26 +0,0 @@ -$NetBSD: patch-aa,v 1.1.1.1 2002/03/24 18:04:58 wiz Exp $ - ---- configure.orig Sat Mar 23 18:10:00 2002 -+++ configure -@@ -3880,8 +3880,8 @@ - - XLIBS="-lX11 $X_EXTRA_LIBS" - --lib_search_path="$lib_search_path $XLFLAGS -L/usr/local/lib" --inc_search_path="$inc_search_path $XCFLAGS -I/usr/local/include" -+lib_search_path="$lib_search_path $XLFLAGS" -+inc_search_path="$inc_search_path $XCFLAGS" - - - -@@ -4359,6 +4359,10 @@ - ;; - openbsd*) - OS=openbsd -+ ignore_nice=yes -+ ;; -+netbsd*) -+ OS=netbsd - ignore_nice=yes - ;; - solaris*) diff --git a/sysutils/wmcpuload/patches/patch-ab b/sysutils/wmcpuload/patches/patch-ab deleted file mode 100644 index 401bb94d672..00000000000 --- a/sysutils/wmcpuload/patches/patch-ab +++ /dev/null @@ -1,12 +0,0 @@ -$NetBSD: patch-ab,v 1.1.1.1 2002/03/24 18:04:57 wiz Exp $ - ---- src/Makefile.am.orig Sat Mar 23 10:19:34 2002 -+++ src/Makefile.am -@@ -14,6 +14,7 @@ - cpu_linux.c \ - cpu_freebsd.c \ - cpu_openbsd.c \ -+ cpu_netbsd.c \ - cpu_solaris.c \ - cpu_cygwin.c - diff --git a/sysutils/wmcpuload/patches/patch-ac b/sysutils/wmcpuload/patches/patch-ac deleted file mode 100644 index f018cbfb0ab..00000000000 --- a/sysutils/wmcpuload/patches/patch-ac +++ /dev/null @@ -1,67 +0,0 @@ -$NetBSD: patch-ac,v 1.1.1.1 2002/03/24 18:04:57 wiz Exp $ - ---- src/cpu_netbsd.c.orig Sun Mar 24 18:18:37 2002 -+++ src/cpu_netbsd.c -@@ -0,0 +1,62 @@ -+/* -+ * cpu_netbsd - module to get cpu usage, for NetBSD -+ * -+ * Copyright (C) 2001, 2002 Seiichi SATO -+ * -+ * Licensed under the GPL -+ */ -+ -+#ifdef HAVE_CONFIG_H -+#include "config.h" -+#endif -+ -+#include -+#include -+#include -+#include -+#include "cpu.h" -+ -+#include -+#include -+#include -+#include -+ -+void cpu_init(void) -+{ -+ /* You don't need initialization under NetBSD */ -+ return; -+} -+ -+/* Returns the current CPU usage in percent */ -+int cpu_get_usage(struct cpu_options *opts) -+{ -+ int total, used, result; -+ static int pre_total, pre_used; -+ -+ int mib[] = { CTL_KERN, KERN_CP_TIME }; -+ u_int64_t cpu_time[CPUSTATES]; -+ size_t size = sizeof(cpu_time); -+ -+ /* get cpu time*/ -+ if (sysctl(mib, 2, &cpu_time, &size, NULL, 0) < 0) -+ return 0; -+ -+ /* calc usage */ -+ used = cpu_time[CP_USER] + cpu_time[CP_SYS]; -+ if (!opts->ignore_nice) -+ used += cpu_time[CP_NICE]; -+ total = used + cpu_time[CP_IDLE]; -+ -+ if (pre_total == 0) -+ result = 0; -+ else if ((total - pre_total) > 0) -+ result = 100 * (double)(used - pre_used) / (double)(total - pre_total); -+ else -+ result = 0; -+ -+ /* save used/total for next calculation */ -+ pre_used = used; -+ pre_total = total; -+ -+ return result; -+} -- cgit v1.2.3