Merge branch 'collectd-4.2' into collectd-4.3
authorFlorian Forster <octo@huhu.verplant.org>
Wed, 30 Apr 2008 08:59:19 +0000 (10:59 +0200)
committerFlorian Forster <octo@huhu.verplant.org>
Wed, 30 Apr 2008 08:59:19 +0000 (10:59 +0200)
Conflicts:

configure.in
src/perl.c

configure.in
src/load.c
src/perl.c

index c99fe17..4da57fc 100644 (file)
@@ -1095,17 +1095,13 @@ AM_CONDITIONAL(BUILD_WITH_LIBCURL, test "x$with_libcurl" = "xyes")
 ### END of check for libcurl ###
 
 with_libiokit="no"
-collectd_libiokit=0
 AC_CHECK_LIB(IOKit, IOServiceGetMatchingServices,
 [
        with_libiokit="yes"
-       collectd_libiokit=1
-],
+], 
 [
        with_libiokit="no"
-       collectd_libiokit=0
 ])
-AC_DEFINE_UNQUOTED(COLLECT_LIBIOKIT, [$collect_libiokit], [Wether or not to use the IOKit library])
 AM_CONDITIONAL(BUILD_WITH_LIBIOKIT, test "x$with_libiokit" = "xyes")
 
 with_libstatgrab_cflags=""
@@ -1212,6 +1208,7 @@ fi
 AM_CONDITIONAL(BUILD_WITH_LIBSTATGRAB, test "x$with_libstatgrab" = "xyes")
 if test "x$with_libstatgrab" = "xyes"
 then
+  AC_DEFINE(HAVE_LIBSTATGRAB, 1, [Define to 1 if you have the 'statgrab' library (-lstatgrab)])
   BUILD_WITH_LIBSTATGRAB_CFLAGS="$with_libstatgrab_cflags"
   BUILD_WITH_LIBSTATGRAB_LDFLAGS="$with_libstatgrab_ldflags"
   AC_SUBST(BUILD_WITH_LIBSTATGRAB_CFLAGS)
index db3bf4b..15215d3 100644 (file)
@@ -116,7 +116,7 @@ static int load_read (void)
        load_submit (snum, mnum, lnum);
 /* #endif KERNEL_LINUX */
 
-#elif defined(HAVE_LIBSTATGRAB)
+#elif HAVE_LIBSTATGRAB
        gauge_t snum, mnum, lnum;
        sg_load_stats *ls;
 
index 96e8562..877bc00 100644 (file)
@@ -1364,6 +1364,11 @@ static int init_pi (int argc, char **argv)
                exit (1);
        }
 
+#ifdef __FreeBSD__
+       /* On FreeBSD, PERL_SYS_INIT3 expands to some expression which
+        * triggers a "value computed is not used" warning by gcc. */
+       (void)
+#endif
        PERL_SYS_INIT3 (&argc, &argv, &environ);
 
        perl_threads = (c_ithread_list_t *)smalloc (sizeof (c_ithread_list_t));