Merge branch 'collectd-5.7'
authorMarc Fournier <marc.fournier@camptocamp.com>
Tue, 10 Jan 2017 22:03:15 +0000 (23:03 +0100)
committerMarc Fournier <marc.fournier@camptocamp.com>
Tue, 10 Jan 2017 22:03:15 +0000 (23:03 +0100)
configure.ac
contrib/redhat/collectd.spec
src/curl_json.c

index c0fe54e..1b9b3fb 100644 (file)
@@ -4225,6 +4225,16 @@ then
 fi
 if test "x$with_libpqos" = "xyes"
 then
+  SAVE_CPPFLAGS="$CPPFLAGS"
+  CPPFLAGS="$CPPFLAGS $with_libpqos_cppflags"
+  AC_RUN_IFELSE([AC_LANG_PROGRAM(
+    [[#include <pqos.h>]],
+    [[return !(PQOS_VERSION >= 106)]])],
+    [with_libpqos="yes"], [with_libpqos="no (pqos library version 1.06 or higher is required)"])
+  CPPFLAGS="$SAVE_CPPFLAGS"
+fi
+if test "x$with_libpqos" = "xyes"
+then
        BUILD_WITH_LIBPQOS_CPPFLAGS="$with_libpqos_cppflags"
        BUILD_WITH_LIBPQOS_LDFLAGS="$with_libpqos_ldflags"
        BUILD_WITH_LIBPQOS_LIBS="-lpqos"
index 8726d7c..350c357 100644 (file)
 %define with_write_log 0%{!?_without_write_log:1}
 %define with_write_prometheus 0%{!?_without_write_prometheus:1}
 %define with_write_redis 0%{!?_without_write_redis:1}
+%define with_write_riemann 0%{!?_without_write_riemann:1}
 %define with_write_sensu 0%{!?_without_write_sensu:1}
 %define with_write_tsdb 0%{!?_without_write_tsdb:1}
 %define with_xmms 0%{!?_without_xmms:0%{?_has_xmms}}
 %define with_write_kafka 0%{!?_without_write_kafka:0}
 # plugin write_mongodb disabled, requires libmongoc
 %define with_write_mongodb 0%{!?_without_write_mongodb:0}
-# plugin write_riemann disabled, requires a new enough riemann_c_client
-%define with_write_riemann 0%{!?_without_write_riemann:0}
 # plugin xencpu disabled, requires xen-devel from non-default repo
 %define with_xencpu 0%{!?_without_xencpu:0}
 # plugin zone disabled, requires Solaris
 %define with_turbostat 0
 %define with_write_prometheus 0
 %define with_write_redis 0
+%define with_write_riemann 0
 %endif
 
 # Plugins not buildable on RHEL < 7
 %define with_redis 0
 %define with_rrdcached 0
 %define with_write_redis 0
+%define with_write_riemann 0
 %define with_xmms 0
 %endif
 
@@ -883,7 +884,7 @@ The Write Redis plugin stores values in Redis, a “data structures server”.
 Summary:       riemann plugin for collectd
 Group:         System Environment/Daemons
 Requires:      %{name}%{?_isa} = %{version}-%{release}
-BuildRequires: protobuf-c-devel
+BuildRequires: riemann-c-client-devel >= 1.6
 %description write_riemann
 The riemann plugin submits values to Riemann, an event stream processor.
 %endif
index 8e09bd8..4d8677a 100644 (file)
@@ -600,7 +600,7 @@ static int cj_init_curl(cj_t *db) /* {{{ */
     curl_easy_setopt(db->curl, CURLOPT_TIMEOUT_MS, (long)db->timeout);
   else if (db->interval > 0)
     curl_easy_setopt(db->curl, CURLOPT_TIMEOUT_MS,
-                     (long)CDTIME_T_TO_MS(db->timeout));
+                     (long)CDTIME_T_TO_MS(db->interval));
   else
     curl_easy_setopt(db->curl, CURLOPT_TIMEOUT_MS,
                      (long)CDTIME_T_TO_MS(plugin_get_interval()));