From 55f646b06e7abe5c0e8359a60dfa2058619a1f1d Mon Sep 17 00:00:00 2001 From: Andrew Bays Date: Tue, 19 Jun 2018 10:56:09 -0400 Subject: [PATCH] Connectivity RPM specfile --- contrib/redhat/collectd.spec | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/contrib/redhat/collectd.spec b/contrib/redhat/collectd.spec index 8bde54c2..8355ee5a 100644 --- a/contrib/redhat/collectd.spec +++ b/contrib/redhat/collectd.spec @@ -53,6 +53,7 @@ %define with_ceph 0%{!?_without_ceph:1} %define with_cgroups 0%{!?_without_cgroups:1} %define with_chrony 0%{!?_without_chrony:1} +%define with_connectivity 0%{!?_without_connectivity:1} %define with_conntrack 0%{!?_without_conntrack:1} %define with_contextswitch 0%{!?_without_contextswitch:1} %define with_cpu 0%{!?_without_cpu:1} @@ -248,6 +249,7 @@ # Plugins not buildable on RHEL < 7 %if 0%{?rhel} && 0%{?rhel} < 7 +%define with_connectivity 0 %define with_cpusleep 0 %define with_gps 0 %define with_mqtt 0 @@ -384,6 +386,16 @@ Requires: %{name}%{?_isa} = %{version}-%{release} Chrony plugin for collectd %endif +%if %{with_connectivity} +%package connectivity +Summary: Connectivity plugin for collectd +Group: System Environment/Daemons +Requires: %{name}%{?_isa} = %{version}-%{release} +BuildRequires: yajl-devel +%description connectivity +Monitors network interface up/down status via netlink library. +%endif + %if %{with_curl} %package curl Summary: Curl plugin for collectd @@ -1160,6 +1172,12 @@ Collectd utilities %define _with_chrony --disable-chrony %endif ++%if %{with_connectivity} ++%define _with_connectivity --enable-connectivity ++%else ++%define _with_connectivity --disable-connectivity ++%endif + %if %{with_conntrack} %define _with_conntrack --enable-conntrack %else @@ -2028,6 +2046,7 @@ Collectd utilities %{?_with_ceph} \ %{?_with_cgroups} \ %{?_with_chrony} \ + %{?_with_connectivity} \ %{?_with_conntrack} \ %{?_with_contextswitch} \ %{?_with_cpufreq} \ @@ -2577,6 +2596,11 @@ fi %{_libdir}/%{name}/chrony.so %endif +%if %{with_connectivity} +%files connectivity +%{_libdir}/%{name}/connectivity.so +%endif + %if %{with_curl} %files curl %{_libdir}/%{name}/curl.so -- 2.11.0