Hi Thorsten, On Fri, Oct 09, 2009 at 11:46:26AM -0700, Thorsten von Eicken wrote: > - rrdtool trunk rev 1889 (had trouble compiling collectd with newer > versions)
this is a bug introduced in RRDtool in revision 1906: src/rrd_client.h will do the following check / include: #ifdef HAVE_CONFIG_H #include "../rrd_config.h" #endif Of course “HAVE_CONFIG_H” is defined when building collectd - it's using the autotools, too. The (now globally available) config file will try to include "../rrd_config.h" and fail because it is not there. I don't think this inclusion is necessary when building RRDtool: Basically the same check / inclusion is done within src/rrd_tool.h. All we have to do is to make sure all .c-files within RRDtool include this header before including src/rrd_client.h. The only file doing this in the wrong order is src/rrd_client.c (I just checked). With the attached patch against revision 1934 I was able to build the rrdcached plugin of collectd without problems. Regards, —octo -- Florian octo Forster Hacker in training GnuPG: 0x91523C3D http://verplant.org/
commit 0299e04d2ed41324a38f6d3d90e1614a0b0e3f0d Author: Florian Forster <o...@leeloo.lan.home.verplant.org> Date: Sat Oct 10 12:16:21 2009 +0200 src/rrd_client.[ch]: Fix build issues introduced in revision 1906. diff --git a/src/rrd_client.c b/src/rrd_client.c index a4f1ba9..b018ee0 100644 --- a/src/rrd_client.c +++ b/src/rrd_client.c @@ -21,8 +21,8 @@ **/ #include "rrd.h" -#include "rrd_client.h" #include "rrd_tool.h" +#include "rrd_client.h" #include <stdlib.h> #include <string.h> diff --git a/src/rrd_client.h b/src/rrd_client.h index 787c2b6..6c48dec 100644 --- a/src/rrd_client.h +++ b/src/rrd_client.h @@ -22,14 +22,6 @@ #ifndef __RRD_CLIENT_H #define __RRD_CLIENT_H 1 -#if defined(_WIN32) && !defined(__CYGWIN__) && !defined(__CYGWIN32__) && !defined(HAVE_CONFIG_H) -#include "../win32/config.h" -#else -#ifdef HAVE_CONFIG_H -#include "../rrd_config.h" -#endif -#endif - #ifndef WIN32 # ifdef HAVE_STDINT_H # include <stdint.h>
signature.asc
Description: Digital signature
_______________________________________________ rrd-developers mailing list rrd-developers@lists.oetiker.ch https://lists.oetiker.ch/cgi-bin/listinfo/rrd-developers