summaryrefslogtreecommitdiff
path: root/sysutils/gkrellm/patches
diff options
context:
space:
mode:
authorcube <cube@pkgsrc.org>2005-09-08 13:19:56 +0000
committercube <cube@pkgsrc.org>2005-09-08 13:19:56 +0000
commitb376b0a3ef8c53afc60322f12ce46bab363c42d0 (patch)
tree68a36a202c94a1951b5fd21325abc6a43c1cd1a6 /sysutils/gkrellm/patches
parent548c3b528c7ee9557685a1120d10f5a2e77646aa (diff)
downloadpkgsrc-b376b0a3ef8c53afc60322f12ce46bab363c42d0.tar.gz
Update gkrellm to version 2.2.7.
pkgsrc changes: - use REQD_DIRS where appropriate - add a patch to allow gkrellm to read everything off sysctl() and thus don't install it setgid kem on NetBSD 3.99.1+ - use options framework to choose between OpenSSL and gnutls - minor nits gkrellm changes: 2.2.7 - Tue May 24, 2005 ------------------------ * gkrellmd can send a network interface connect time to be displayed on client timer button panels by configuring a net-timer in gkrellmd.conf. * Don't add virtual disk (/dev/mdX) stats to composite disk. * Bugfixes: o server/main.c inet6 compile error on machines with old libc. o Philipp Hartmann patch: add gnutls multithread initialization to mail.c o While mixing draw_decal_text and decal_scroll_text calls on transparent panels the text layer pixmap was not cleanup up properly. * Translation updates 2.2.6 - Fri May 13, 2005 ------------------------ * Stanislav Likavcan patch: add monitoring of ibm acpi sensors to linux.c. * UI improvement in fs.c and mail.c config button sensitivities and labels. * Bugfixes: o Test for not force creating user mailbox did not consider a configured mail fetch. o gkrellmd server mail check was missing the gkrellmd_need_serve() call and server/mail.c mailbox code needed syncing with src/mail.c. o gkrellmd glib 1.2 g_file_test compatibility was broken. o gkrellmd debug-level option was missing. o Darwin Makefile: add HAVE_GETADDRINFO=1 o Don Bostrom patch: when remote mail checking, handle select() EINTR. o Charles Bailey patches: 1) darwin.c and Makefile tweaks for building on OS X 10.3.8. 2) darwin.c prevent left bit sign extension when shifting memory monitor data. o Don't read disabled sensors in the sensors thread. * Translation updates
Diffstat (limited to 'sysutils/gkrellm/patches')
-rw-r--r--sysutils/gkrellm/patches/patch-ab94
-rw-r--r--sysutils/gkrellm/patches/patch-ad22
-rw-r--r--sysutils/gkrellm/patches/patch-aq18
-rw-r--r--sysutils/gkrellm/patches/patch-ar25
-rw-r--r--sysutils/gkrellm/patches/patch-as14
5 files changed, 148 insertions, 25 deletions
diff --git a/sysutils/gkrellm/patches/patch-ab b/sysutils/gkrellm/patches/patch-ab
index 677aacae15a..dc4017a3804 100644
--- a/sysutils/gkrellm/patches/patch-ab
+++ b/sysutils/gkrellm/patches/patch-ab
@@ -1,6 +1,6 @@
-$NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
+$NetBSD: patch-ab,v 1.14 2005/09/08 13:19:56 cube Exp $
---- src/sysdeps/netbsd.c.orig 2004-05-01 19:46:38.000000000 +0200
+--- src/sysdeps/netbsd.c.orig 2005-05-24 05:45:10.000000000 +0200
+++ src/sysdeps/netbsd.c
@@ -63,7 +63,8 @@ gkrellm_sys_cpu_read_data(void)
{
@@ -82,7 +82,7 @@ $NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
if (getloadavg(&avenrun, 1) <= 0)
avenrun = 0;
gkrellm_proc_assign_data(n_processes, 0, n_forks, avenrun);
-@@ -183,6 +178,97 @@ gkrellm_sys_proc_init(void)
+@@ -183,6 +178,96 @@ gkrellm_sys_proc_init(void)
/* ===================================================================== */
@@ -91,7 +91,6 @@ $NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
+#include <sys/vmmeter.h>
+#include <sys/sysctl.h>
+#include <uvm/uvm_extern.h>
-+#include <kvm.h>
+
+
+void
@@ -180,7 +179,7 @@ $NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
/* Sensor monitor interface */
/* Tables of voltage correction factors and offsets derived from the
-@@ -295,7 +381,7 @@ gkrellm_sys_sensors_init(void)
+@@ -295,7 +380,7 @@ gkrellm_sys_sensors_init(void)
int fd; /* file desc. for /dev/sysmon */
int id = 0; /* incremented for each sensor */
int type;
@@ -189,7 +188,7 @@ $NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
gboolean found_sensors = FALSE;
/* check if some sensor is configured */
-@@ -336,3 +422,68 @@ gkrellm_sys_sensors_init(void)
+@@ -336,3 +421,149 @@ gkrellm_sys_sensors_init(void)
return found_sensors;
}
@@ -240,7 +239,7 @@ $NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
+ wbytes = 0;
+#endif
+
-+ gkrellm_disk_assign_data_by_name(dk_drives[i].dk_name, rbytes, wbytes);
++ gkrellm_disk_assign_data_by_name(dk_drives[i].dk_name, rbytes, wbytes, FALSE);
+ }
+
+ free(dk_drives);
@@ -258,3 +257,84 @@ $NetBSD: patch-ab,v 1.13 2004/07/05 08:42:27 cube Exp $
+ {
+ return -1; /* append disk charts as added */
+ }
++
++#if __NetBSD_Version__ >= 399000100
++
++#include "../inet.h"
++
++#include <errno.h>
++#include <sys/socket.h>
++#include <netinet/in.h>
++#include <netinet/tcp_fsm.h>
++
++static const struct gkrellm_inet_fam {
++ sa_family_t family;
++ const char *mib;
++} families[] = { {AF_INET, "net.inet.tcp.pcblist"},
++#ifdef INET6
++ {AF_INET6, "net.inet6.tcp6.pcblist"},
++#endif
++ {0, NULL} };
++
++void
++gkrellm_sys_inet_read_tcp_data()
++{
++ ActiveTCP tcp;
++ int mib[CTL_MAXNAME], i;
++ size_t sz;
++ u_int namelen;
++ struct kinfo_pcb *pcbt = NULL;
++ const struct gkrellm_inet_fam *pf = families;
++
++ while (pf->mib != NULL) {
++ sz = CTL_MAXNAME;
++ if (sysctlnametomib(pf->mib, mib, &sz) == -1)
++ return;
++ namelen = sz;
++
++ mib[namelen++] = PCB_ALL;
++ mib[namelen++] = 0;
++ mib[namelen++] = sizeof(struct kinfo_pcb);
++ mib[namelen++] = INT_MAX;
++
++ sz = 0;
++ pcbt = NULL;
++ if (sysctl(&mib[0], namelen, pcbt, &sz, NULL, 0) == -1)
++ return;
++ pcbt = malloc(sz);
++ if (pcbt == NULL)
++ return;
++ if (sysctl(&mib[0], namelen, pcbt, &sz, NULL, 0) == -1)
++ return;
++
++ sz /= sizeof(struct kinfo_pcb);
++ for (i = 0; i < sz; i++) {
++ tcp.family = pf->family;
++ if (pf->family == AF_INET) {
++ struct sockaddr_in *sin =
++ (struct sockaddr_in *)&pcbt[i].ki_dst;
++ tcp.remote_addr.s_addr = sin->sin_addr.s_addr;
++ tcp.remote_port = sin->sin_port;
++
++ sin = (struct sockaddr_in *)&pcbt[i].ki_src;
++ tcp.local_port = sin->sin_port;
++#ifdef INET6
++ } else { /* AF_INET6 */
++ struct sockaddr_in6 *sin =
++ (struct sockaddr_in6 *)&pcbt[i].ki_dst;
++ memcpy(&tcp.remote_addr6, &sin->sin6_addr,
++ sizeof(struct in6_addr));
++ tcp.remote_port = sin->sin6_port;
++
++ sin = (struct sockaddr_in6 *)&pcbt[i].ki_src;
++ tcp.local_port = sin->sin6_port;
++#endif
++ }
++ if (pcbt[i].ki_tstate == TCPS_ESTABLISHED)
++ gkrellm_inet_log_tcp_port_data(&tcp);
++ }
++ free(pcbt);
++ pf++;
++ }
++}
++#endif
diff --git a/sysutils/gkrellm/patches/patch-ad b/sysutils/gkrellm/patches/patch-ad
index ec50bbd1ec1..b65498819d8 100644
--- a/sysutils/gkrellm/patches/patch-ad
+++ b/sysutils/gkrellm/patches/patch-ad
@@ -1,8 +1,8 @@
-$NetBSD: patch-ad,v 1.1 2004/06/07 17:01:50 cube Exp $
+$NetBSD: patch-ad,v 1.2 2005/09/08 13:19:56 cube Exp $
---- src/sysdeps/bsd-net-open.c.orig 2004-05-01 19:46:38.000000000 +0200
+--- src/sysdeps/bsd-net-open.c.orig 2005-05-24 05:44:48.000000000 +0200
+++ src/sysdeps/bsd-net-open.c
-@@ -23,108 +23,6 @@
+@@ -23,110 +23,10 @@
/* ===================================================================== */
@@ -76,7 +76,7 @@ $NetBSD: patch-ad,v 1.1 2004/06/07 17:01:50 cube Exp $
- wbytes = 0;
-#endif
-
-- gkrellm_disk_assign_data_by_name(buf, rbytes, wbytes);
+- gkrellm_disk_assign_data_by_name(buf, rbytes, wbytes, FALSE);
- }
- }
-}
@@ -110,8 +110,20 @@ $NetBSD: patch-ad,v 1.1 2004/06/07 17:01:50 cube Exp $
-/* ===================================================================== */
/* Inet monitor interface */
++#if defined(__OpenBSD__) || ( defined(__NetBSD__) && __NetBSD_Version__ < 399000100 )
++
#include "../inet.h"
-@@ -199,95 +97,6 @@ gkrellm_sys_inet_init(void)
+
+ /* NO IPv6 SUPPORT YET */
+@@ -191,6 +91,7 @@ gkrellm_sys_inet_read_tcp_data(void)
+ next = (struct inpcb *)inpcb.inp_queue.cqe_next;
+ }
+ }
++#endif
+
+ gboolean
+ gkrellm_sys_inet_init(void)
+@@ -199,95 +100,6 @@ gkrellm_sys_inet_init(void)
}
/* ===================================================================== */
diff --git a/sysutils/gkrellm/patches/patch-aq b/sysutils/gkrellm/patches/patch-aq
index e32b5415eb6..69ee6a8b99b 100644
--- a/sysutils/gkrellm/patches/patch-aq
+++ b/sysutils/gkrellm/patches/patch-aq
@@ -1,8 +1,20 @@
-$NetBSD: patch-aq,v 1.1 2005/03/30 15:26:43 cube Exp $
+$NetBSD: patch-aq,v 1.2 2005/09/08 13:19:56 cube Exp $
---- server/main.c.orig 2005-03-11 16:03:54.000000000 +0100
+--- server/main.c.orig 2005-05-24 05:46:38.000000000 +0200
+++ server/main.c
-@@ -1051,7 +1051,7 @@ main(gint argc, gchar **argv)
+@@ -203,7 +203,10 @@ cidr_match(struct sockaddr *sa, socklen_
+ char *p, *ep;
+ guchar *addr, *pat;
+ u_int32_t mask;
+- int plen, i;
++ int plen;
++#if defined(INET6)
++ int i;
++#endif
+ gboolean result;
+
+ buf = g_strdup(allowed);
+@@ -1062,7 +1065,7 @@ main(gint argc, gchar **argv)
{
client_fd = accept(server_fd,
(struct sockaddr *) &client_addr,
diff --git a/sysutils/gkrellm/patches/patch-ar b/sysutils/gkrellm/patches/patch-ar
index 6ed46ed8975..1bef56d130e 100644
--- a/sysutils/gkrellm/patches/patch-ar
+++ b/sysutils/gkrellm/patches/patch-ar
@@ -1,21 +1,26 @@
-$NetBSD: patch-ar,v 1.1 2005/03/30 15:26:43 cube Exp $
+$NetBSD: patch-ar,v 1.2 2005/09/08 13:19:56 cube Exp $
---- server/monitor.c.orig 2005-03-09 17:25:01.000000000 +0100
+--- server/monitor.c.orig 2005-05-24 06:29:32.000000000 +0200
+++ server/monitor.c
-@@ -550,10 +550,10 @@ serve_disk_data(GkrellmdMonitor *mon, gb
- if (!disk->changed && !first_serve)
- continue;
+@@ -555,14 +555,14 @@ serve_disk_data(GkrellmdMonitor *mon, gb
if (!disk->subdisk_parent)
-- snprintf(buf, sizeof(buf), "%s %llu %llu\n",
-+ snprintf(buf, sizeof(buf), "%s %" PRIu64 " %" PRIu64 "\n",
- disk->name, disk->rb, disk->wb);
+ {
+ if (gkrellmd_check_client_version(mon, 2, 2, 7) && disk->virtual)
+- snprintf(buf, sizeof(buf), "%s virtual %llu %llu\n",
++ snprintf(buf, sizeof(buf), "%s virtual %" PRIu64 " %" PRIu64 "\n",
+ disk->name, disk->rb, disk->wb);
+ else
+- snprintf(buf, sizeof(buf), "%s %llu %llu\n",
++ snprintf(buf, sizeof(buf), "%s %" PRIu64 " %" PRIu64 "\n",
+ disk->name, disk->rb, disk->wb);
+ }
else if (mon->privat->client->feature_subdisk)
- snprintf(buf, sizeof(buf), "%s %s %llu %llu\n",
+ snprintf(buf, sizeof(buf), "%s %s %" PRIu64 " %" PRIu64 "\n",
disk->name, disk->subdisk_parent, disk->rb, disk->wb);
else
continue;
-@@ -1134,7 +1134,7 @@ serve_mem_data(GkrellmdMonitor *mon, gbo
+@@ -1233,7 +1233,7 @@ serve_mem_data(GkrellmdMonitor *mon, gbo
if (mem.mem_changed || first_serve)
{
gkrellmd_set_serve_name(mon, "mem");
@@ -24,7 +29,7 @@ $NetBSD: patch-ar,v 1.1 2005/03/30 15:26:43 cube Exp $
mem.total, mem.used, mem.free,
mem.shared, mem.buffers, mem.cached);
gkrellmd_serve_data(mon, buf);
-@@ -1143,7 +1143,7 @@ serve_mem_data(GkrellmdMonitor *mon, gbo
+@@ -1242,7 +1242,7 @@ serve_mem_data(GkrellmdMonitor *mon, gbo
if (mem.swap_changed || first_serve)
{
gkrellmd_set_serve_name(mon, "swap");
diff --git a/sysutils/gkrellm/patches/patch-as b/sysutils/gkrellm/patches/patch-as
new file mode 100644
index 00000000000..727c49b624c
--- /dev/null
+++ b/sysutils/gkrellm/patches/patch-as
@@ -0,0 +1,14 @@
+$NetBSD: patch-as,v 1.1 2005/09/08 13:19:56 cube Exp $
+
+--- src/configure.orig 2005-05-24 05:27:10.000000000 +0200
++++ src/configure
+@@ -17,9 +17,6 @@ do
+ fi
+ done
+
+-PKG_INCLUDE=`pkg-config gtk+-2.0 --cflags`
+-PKG_LIB=`pkg-config gtk+-2.0 --libs`
+-
+ rm -f configure.h configure.log test test.o test.c
+
+ touch configure.h