X-Git-Url: https://git.octo.it/?p=rrdtool.git;a=blobdiff_plain;f=configure.ac;h=8e64c11a93831303510248901aa37838b6bc4c7f;hp=4061795badf2e6595df1a3949f7e9acfe3bf2760;hb=f3df7df77761c610c9ba328fac01619f4e7b563f;hpb=4af79d1fe0fbb9655cf28a0989d2e98b94b37460 diff --git a/configure.ac b/configure.ac index 4061795..8e64c11 100644 --- a/configure.ac +++ b/configure.ac @@ -56,7 +56,7 @@ AH_BOTTOM([ /* define strrchr, strchr and memcpy, memmove in terms of bsd funcs make sure you are NOT using bcopy, index or rindex in the code */ -#if STDC_HEADERS +#ifdef STDC_HEADERS # include #else # ifndef HAVE_STRCHR @@ -70,30 +70,34 @@ char *strchr (), *strrchr (); # endif #endif +/* enable posix_fadvise on linux */ +#ifdef HAVE_POSIX_FADVISE +#define __USE_XOPEN2K 1 +#endif -#if NO_NULL_REALLOC +#ifdef NO_NULL_REALLOC # define rrd_realloc(a,b) ( (a) == NULL ? malloc( (b) ) : realloc( (a) , (b) )) #else # define rrd_realloc(a,b) realloc((a), (b)) #endif -#if NEED_MALLOC_MALLOC_H +#ifdef NEED_MALLOC_MALLOC_H # include #endif -#if HAVE_MATH_H +#ifdef HAVE_MATH_H # include #endif -#if HAVE_FLOAT_H +#ifdef HAVE_FLOAT_H # include #endif -#if HAVE_IEEEFP_H +#ifdef HAVE_IEEEFP_H # include #endif -#if HAVE_FP_CLASS_H +#ifdef HAVE_FP_CLASS_H # include #endif @@ -243,7 +247,7 @@ AC_C_BIGENDIAN dnl for each function found we get a definition in config.h dnl of the form HAVE_FUNCTION -AC_CHECK_FUNCS(tzset mbstowcs opendir readdir chdir chroot getuid setlocale strerror strerror_r snprintf vsnprintf fpclass class fp_class isnan memmove strchr mktime getrusage gettimeofday) +AC_CHECK_FUNCS(tzset mbstowcs opendir readdir chdir chroot getuid setlocale strerror strerror_r snprintf vsnprintf fpclass class fp_class isnan memmove strchr mktime getrusage gettimeofday posix_fadvise) if test "x$enable_mmap" = xyes; then