package/collectd: add nut support
authorBernd Kuhls <bernd.kuhls@t-online.de>
Sat, 22 Aug 2020 08:56:43 +0000 (10:56 +0200)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Mon, 24 Aug 2020 20:55:59 +0000 (22:55 +0200)
The NUT plugin has status "supported":
https://collectd.org/wiki/index.php/Plugin:NUT

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/collectd/Config.in
package/collectd/collectd.mk

index cd5d876e80a43b2aa6ac0d56dd416d4c7af0ad7b..a21f230294a2e71e3839717328aa28ca6108e9af 100644 (file)
@@ -364,6 +364,17 @@ config BR2_PACKAGE_COLLECTD_NTPD
        help
          Queries an NTP server and extracts parameters.
 
+config BR2_PACKAGE_COLLECTD_NUT
+       bool "nut"
+       depends on BR2_INSTALL_LIBSTDCPP
+       select BR2_PACKAGE_NUT
+       help
+         The NUT plugin collects uninterruptible power supply (UPS)
+         statistics using the Network UPS Tools (NUT).
+
+comment "nut needs a toolchain w/ C++"
+       depends on !BR2_INSTALL_LIBSTDCPP
+
 config BR2_PACKAGE_COLLECTD_OLSRD
        bool "olsrd"
        help
index 6d084dbe42e7998ebb10b6a698c9078ef6946599..e74dafaa2ecefd80cbf51ba78882148298cfe29d 100644 (file)
@@ -18,7 +18,7 @@ COLLECTD_PLUGINS_DISABLE = \
        apple_sensors aquaero ascent barometer dbi dpdkstat email \
        gmond hddtemp intel_rdt ipmi java lpar \
        madwifi mbmon mic multimeter netapp notify_desktop numa \
-       nut oracle perl pf pinba powerdns python routeros \
+       oracle perl pf pinba powerdns python routeros \
        rrdcached sigrok tape target_v5upgrade teamspeak2 ted \
        tokyotyrant turbostat uuid varnish virt vserver write_kafka \
        write_mongodb xencpu xmms zfs_arc zone
@@ -103,6 +103,7 @@ COLLECTD_CONF_OPTS += \
        $(if $(BR2_PACKAGE_COLLECTD_NOTIFY_EMAIL),--enable-notify_email,--disable-notify_email) \
        $(if $(BR2_PACKAGE_COLLECTD_NOTIFY_NAGIOS),--enable-notify_nagios,--disable-notify_nagios) \
        $(if $(BR2_PACKAGE_COLLECTD_NTPD),--enable-ntpd,--disable-ntpd) \
+       $(if $(BR2_PACKAGE_COLLECTD_NUT),--enable-nut,--disable-nut) \
        $(if $(BR2_PACKAGE_COLLECTD_OLSRD),--enable-olsrd,--disable-olsrd) \
        $(if $(BR2_PACKAGE_COLLECTD_ONEWIRE),--enable-onewire,--disable-onewire) \
        $(if $(BR2_PACKAGE_COLLECTD_OPENLDAP),--enable-openldap,--disable-openldap) \
@@ -168,6 +169,7 @@ COLLECTD_DEPENDENCIES = \
        $(if $(BR2_PACKAGE_COLLECTD_NETLINK),libmnl) \
        $(if $(BR2_PACKAGE_COLLECTD_NGINX),libcurl) \
        $(if $(BR2_PACKAGE_COLLECTD_NOTIFY_EMAIL),libesmtp) \
+       $(if $(BR2_PACKAGE_COLLECTD_NUT),nut) \
        $(if $(BR2_PACKAGE_COLLECTD_ONEWIRE),owfs) \
        $(if $(BR2_PACKAGE_COLLECTD_OPENLDAP),openldap) \
        $(if $(BR2_PACKAGE_COLLECTD_PING),liboping) \