pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/sysutils/collectd
Module Name: pkgsrc
Committed By: he
Date: Thu Jan 19 17:20:42 UTC 2017
Modified Files:
pkgsrc/sysutils/collectd: Makefile distinfo options.mk
pkgsrc/sysutils/collectd/patches: patch-src_processes.c
patch-src_utils__format__kairosdb.c
Added Files:
pkgsrc/sysutils/collectd/patches: patch-src_statsd.c
Log Message:
Reinstate the "processes" plugin for NetBSD by initializing the
two per-process context switch counters to -1, indicating no support.
Our kinfo_lwp structure doesn't contain the context switch counters,
which in the kernel is part of the lwp structure.
Also make this build on netbsd-6 and on ports which don't yet have
nearbyint() by simply defining it as rint() on NetBSD.
Bump PKGREVISION.
To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 pkgsrc/sysutils/collectd/Makefile
cvs rdiff -u -r1.31 -r1.32 pkgsrc/sysutils/collectd/distinfo
cvs rdiff -u -r1.8 -r1.9 pkgsrc/sysutils/collectd/options.mk
cvs rdiff -u -r1.4 -r1.5 \
pkgsrc/sysutils/collectd/patches/patch-src_processes.c
cvs rdiff -u -r0 -r1.1 pkgsrc/sysutils/collectd/patches/patch-src_statsd.c
cvs rdiff -u -r1.3 -r1.4 \
pkgsrc/sysutils/collectd/patches/patch-src_utils__format__kairosdb.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/sysutils/collectd/Makefile
diff -u pkgsrc/sysutils/collectd/Makefile:1.18 pkgsrc/sysutils/collectd/Makefile:1.19
--- pkgsrc/sysutils/collectd/Makefile:1.18 Thu Oct 13 15:17:28 2016
+++ pkgsrc/sysutils/collectd/Makefile Thu Jan 19 17:20:42 2017
@@ -1,7 +1,9 @@
-# $NetBSD: Makefile,v 1.18 2016/10/13 15:17:28 fhajny Exp $
+# $NetBSD: Makefile,v 1.19 2017/01/19 17:20:42 he Exp $
.include "../../sysutils/collectd/Makefile.common"
+PKGREVISION= 1
+
COMMENT= Statistics collection daemon base
RCD_SCRIPTS= collectd
Index: pkgsrc/sysutils/collectd/distinfo
diff -u pkgsrc/sysutils/collectd/distinfo:1.31 pkgsrc/sysutils/collectd/distinfo:1.32
--- pkgsrc/sysutils/collectd/distinfo:1.31 Sat Dec 24 10:16:07 2016
+++ pkgsrc/sysutils/collectd/distinfo Thu Jan 19 17:20:42 2017
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.31 2016/12/24 10:16:07 joerg Exp $
+$NetBSD: distinfo,v 1.32 2017/01/19 17:20:42 he Exp $
SHA1 (collectd-5.6.2.tar.bz2) = 358b53ac5e0b00532d74bd40eb2658c6772d1458
RMD160 (collectd-5.6.2.tar.bz2) = 81818c24db06f7a8922dc24e7be8cbf5d86e050c
@@ -17,8 +17,9 @@ SHA1 (patch-src_irq.c) = 78f1757ff2ed6db
SHA1 (patch-src_libcollectclient_network__buffer.c) = 62924943831e6d0585b103e567888f9af5c46f9e
SHA1 (patch-src_memory.c) = 2934cd50e454fc14d0ec952854c88b0a830fa9a7
SHA1 (patch-src_netstat__udp.c) = 30cb12d25f56c60959658dbd181783212e00cc61
-SHA1 (patch-src_processes.c) = 9a1a7a6943ea05d1a38cedf26e7aab8508df7ff1
+SHA1 (patch-src_processes.c) = dbcbb733b00bd77b0eae6d16f03fb0bcb3cbcbff
+SHA1 (patch-src_statsd.c) = 35f4349d2d2c9bddc0f4770344f969157cd012f6
SHA1 (patch-src_swap.c) = 24da6e04e3006639311e8111f26f72e4fab4054a
SHA1 (patch-src_tcpconns.c) = b85de1d0eb03989df12d9688b38d61733a13c028
SHA1 (patch-src_utils__dns.c) = 138a3168dc109d785412ffd068edab3b4dacca36
-SHA1 (patch-src_utils__format__kairosdb.c) = db5d13e6bbbe5adc07cd8a26ec78902cd3503bec
+SHA1 (patch-src_utils__format__kairosdb.c) = 2f7bde47682d2b877f9bd2d2c794a21c297aa9e5
Index: pkgsrc/sysutils/collectd/options.mk
diff -u pkgsrc/sysutils/collectd/options.mk:1.8 pkgsrc/sysutils/collectd/options.mk:1.9
--- pkgsrc/sysutils/collectd/options.mk:1.8 Thu Oct 13 15:17:28 2016
+++ pkgsrc/sysutils/collectd/options.mk Thu Jan 19 17:20:42 2017
@@ -1,13 +1,13 @@
-# $NetBSD: options.mk,v 1.8 2016/10/13 15:17:28 fhajny Exp $
+# $NetBSD: options.mk,v 1.9 2017/01/19 17:20:42 he Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.collectd
PKG_SUPPORTED_OPTIONS= cpu df interface load memory syslog uptime
PKG_SUGGESTED_OPTIONS+= cpu df interface load memory syslog uptime
PKG_SUPPORTED_OPTIONS.NetBSD+= contextswitch disk entropy irq pf netstat_udp
-PKG_SUPPORTED_OPTIONS.NetBSD+= swap tcpconns users
+PKG_SUPPORTED_OPTIONS.NetBSD+= swap tcpconns users processes
PKG_SUGGESTED_OPTIONS.NetBSD+= contextswitch disk entropy irq pf netstat_udp
-PKG_SUGGESTED_OPTIONS.NetBSD+= swap tcpconns users
+PKG_SUGGESTED_OPTIONS.NetBSD+= swap tcpconns users processes
PKG_SUPPORTED_OPTIONS.FreeBSD+= contextswitch pf processes swap tcpconns zfs-arc
PKG_SUGGESTED_OPTIONS.FreeBSD+= contextswitch pf processes swap tcpconns zfs-arc
Index: pkgsrc/sysutils/collectd/patches/patch-src_processes.c
diff -u pkgsrc/sysutils/collectd/patches/patch-src_processes.c:1.4 pkgsrc/sysutils/collectd/patches/patch-src_processes.c:1.5
--- pkgsrc/sysutils/collectd/patches/patch-src_processes.c:1.4 Wed Dec 7 17:28:39 2016
+++ pkgsrc/sysutils/collectd/patches/patch-src_processes.c Thu Jan 19 17:20:42 2017
@@ -1,8 +1,8 @@
-$NetBSD: patch-src_processes.c,v 1.4 2016/12/07 17:28:39 fhajny Exp $
+$NetBSD: patch-src_processes.c,v 1.5 2017/01/19 17:20:42 he Exp $
Add a port to NetBSD.
---- src/processes.c.orig 2016-11-30 08:52:01.324910450 +0000
+--- src/processes.c.orig 2016-11-30 08:52:01.000000000 +0000
+++ src/processes.c
@@ -95,14 +95,14 @@
/* #endif KERNEL_LINUX */
@@ -63,7 +63,7 @@ Add a port to NetBSD.
#elif HAVE_PROCINFO_H
pagesize = getpagesize();
-@@ -1917,6 +1933,187 @@ static int ps_read(void) {
+@@ -1917,6 +1933,191 @@ static int ps_read(void) {
ps_submit_proc_list(ps_ptr);
/* #endif HAVE_LIBKVM_GETPROCS && HAVE_STRUCT_KINFO_PROC_FREEBSD */
@@ -166,6 +166,10 @@ Add a port to NetBSD.
+ pse.cpu_system = 0;
+ pse.cpu_user_counter = 0;
+ pse.cpu_system_counter = 0;
++ /* context switch counters not implemented */
++ pse.cswitch_vol = -1;
++ pse.cswitch_invol = -1;
++
+ /*
+ * The u-area might be swapped out, and we can't get
+ * at it because we have a crashdump and no swap.
Index: pkgsrc/sysutils/collectd/patches/patch-src_utils__format__kairosdb.c
diff -u pkgsrc/sysutils/collectd/patches/patch-src_utils__format__kairosdb.c:1.3 pkgsrc/sysutils/collectd/patches/patch-src_utils__format__kairosdb.c:1.4
--- pkgsrc/sysutils/collectd/patches/patch-src_utils__format__kairosdb.c:1.3 Sat Dec 24 10:16:07 2016
+++ pkgsrc/sysutils/collectd/patches/patch-src_utils__format__kairosdb.c Thu Jan 19 17:20:42 2017
@@ -1,4 +1,7 @@
-$NetBSD: patch-src_utils__format__kairosdb.c,v 1.3 2016/12/24 10:16:07 joerg Exp $
+$NetBSD: patch-src_utils__format__kairosdb.c,v 1.4 2017/01/19 17:20:42 he Exp $
+
+Cast arguments to isalnum() and tolower() to "unsigned char" to
+squelch warnings.
--- src/utils_format_kairosdb.c.orig 2016-11-30 08:52:01.000000000 +0000
+++ src/utils_format_kairosdb.c
Added files:
Index: pkgsrc/sysutils/collectd/patches/patch-src_statsd.c
diff -u /dev/null pkgsrc/sysutils/collectd/patches/patch-src_statsd.c:1.1
--- /dev/null Thu Jan 19 17:20:42 2017
+++ pkgsrc/sysutils/collectd/patches/patch-src_statsd.c Thu Jan 19 17:20:42 2017
@@ -0,0 +1,19 @@
+$NetBSD: patch-src_statsd.c,v 1.1 2017/01/19 17:20:42 he Exp $
+
+Insert workaround for possibly missing nearbyint().
+(Could be more specific, but test would be ... complicated.)
+
+--- src/statsd.c.orig 2017-01-19 16:24:15.000000000 +0000
++++ src/statsd.c
+@@ -48,6 +48,11 @@
+ #define STATSD_DEFAULT_SERVICE "8125"
+ #endif
+
++#ifdef __NetBSD__
++/* May not have this, could be more specific... */
++#define nearbyint(v) rint((v))
++#endif
++
+ enum metric_type_e { STATSD_COUNTER, STATSD_TIMER, STATSD_GAUGE, STATSD_SET };
+ typedef enum metric_type_e metric_type_t;
+
Home |
Main Index |
Thread Index |
Old Index