From: oetiker Date: Fri, 26 Dec 2008 08:05:03 +0000 (+0000) Subject: Include libgen.h to get prototype for basename in a POSIX conformant way. Fix for... X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=effdadeb1fb61ec4e30705affe51c627ef1d4650;p=rrdtool-all.git Include libgen.h to get prototype for basename in a POSIX conformant way. Fix for #202. git-svn-id: svn://svn.oetiker.ch/rrdtool/branches/1.3@1723 a5681a0c-68f1-0310-ab6d-d61299d08faa --- diff --git a/program/configure.ac b/program/configure.ac index a7008312..049e9d0d 100644 --- a/program/configure.ac +++ b/program/configure.ac @@ -160,7 +160,7 @@ CONFIGURE_PART(Checking for Header Files) dnl Checks for header files. AC_HEADER_STDC AC_HEADER_DIRENT -AC_CHECK_HEADERS(features.h sys/stat.h sys/types.h fcntl.h locale.h fp_class.h malloc.h unistd.h ieeefp.h math.h sys/times.h sys/param.h sys/resource.h signal.h float.h stdio.h stdlib.h errno.h string.h ctype.h) +AC_CHECK_HEADERS(libgen.h features.h sys/stat.h sys/types.h fcntl.h locale.h fp_class.h malloc.h unistd.h ieeefp.h math.h sys/times.h sys/param.h sys/resource.h signal.h float.h stdio.h stdlib.h errno.h string.h ctype.h) dnl Checks for typedefs, structures, and compiler characteristics. AC_C_CONST diff --git a/program/src/rrd_graph.h b/program/src/rrd_graph.h index a42b20b6..1cab51e2 100644 --- a/program/src/rrd_graph.h +++ b/program/src/rrd_graph.h @@ -11,6 +11,11 @@ #include #include +#ifdef HAVE_LIBGEN_H +/* for basename */ +# include +#endif + #include "rrd_tool.h" #include "rrd_rpncalc.h"