X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=configure.ac;h=7b7155e9813f67f5f4654308e251d2e1358aa6a2;hb=e6d6ed89bc84009c5ea94d5e2c770833afb80f21;hp=ea2c83905f2492feeeeb6a35967595de35280155;hpb=3e6928b620babaef568bb2ec65dea6a05d618104;p=rrdtool.git diff --git a/configure.ac b/configure.ac index ea2c839..7b7155e 100644 --- a/configure.ac +++ b/configure.ac @@ -167,7 +167,7 @@ else SO_EXT=`$PERL -e 'use Config; if (defined $Config{so} and $Config{so} ne 'a') {print "$Config{so}\n"} else {print "so\n"};'` AC_MSG_RESULT($SO_EXT) AC_MSG_CHECKING(for the C compiler perl wants to use to build its modules) - PROBLEMCC=`$PERL -e 'use Config; map {if (-x "$_/$Config{cc}"){exit 0}} split /:/, $ENV{PATH};print $Config{cc}'` + PROBLEMCC=`$PERL -e 'use Config; ($cc = $Config{cc}) =~ s/\s.*//; exit 0 if -x $cc; map {if (-x "$_/$cc"){exit 0}} split /:/, $ENV{PATH};print $Config{cc}'` if test x$PROBLEMCC != x; then AC_MSG_RESULT(no) echo Could not find the Compiler: '"'$PROBLEMCC'"' @@ -230,7 +230,8 @@ AC_PROG_LIBTOOL dnl Checks for header files. AC_HEADER_STDC -AC_CHECK_HEADERS(fcntl.h time.h locale.h fp_class.h malloc.h unistd.h ieeefp.h math.h sys/time.h sys/times.h sys/param.h sys/resource.h float.h) +AC_HEADER_DIRENT +AC_CHECK_HEADERS(sys/stat.h sys/types.h fcntl.h time.h locale.h fp_class.h malloc.h unistd.h ieeefp.h math.h sys/time.h sys/times.h sys/param.h sys/resource.h float.h) dnl Checks for typedefs, structures, and compiler characteristics. AC_C_CONST @@ -247,7 +248,7 @@ AC_PATH_PROGS(TROFF, groff troff) dnl Does the compiler like -Wall and -pedantic? if test "x$GCC" = "xyes"; then oCFLAGS=$CFLAGS - CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wcast-align -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline" + CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wcast-align -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -W" AC_CACHE_CHECK(if we can use GCC-specific compiler options, rd_cv_gcc_opt, [AC_TRY_COMPILE( , return 0 , rd_cv_gcc_opt=yes, @@ -278,7 +279,7 @@ AC_FUNC_VPRINTF dnl for each function found we get a definition in config.h dnl of the form HAVE_FUNCTION -AC_CHECK_FUNCS(tzset setlocale strerror snprintf vsnprintf fpclass class fp_class isnan memmove strchr mktime getrusage gettimeofday) +AC_CHECK_FUNCS(tzset opendir readdir chdir chroot getuid setlocale strerror snprintf vsnprintf fpclass class fp_class isnan memmove strchr mktime getrusage gettimeofday) dnl HP-UX 11.00 does not have finite but does have isfinite as a macro AC_CHECK_FUNCS(fpclassify, , @@ -415,22 +416,24 @@ AC_IEEE([out of the box], works, , , , AC_IEEE([with the -mieee switch], mswitch, , , , [CFLAGS="$_cflags -q float=rndsngl" AC_IEEE([with the -q float=rndsngl switch], qswitch, , , , - [CFLAGS="$_cflags -OPT:IEEE_comparisons=ON" - AC_IEEE([with the -OPT:IEEE_comparisons=ON switch], ieeecmpswitch, , , , - [CFLAGS=$_cflags - AC_IEEE([with fpsetmask(0)], mask, - [#include ], [fpsetmask(0)], - [AC_DEFINE(MUST_DISABLE_FPMASK) - PERLFLAGS="CCFLAGS=-DMUST_DISABLE_FPMASK"], - [AC_IEEE([with signal(SIGFPE,SIG_IGN)], sigfpe, - [#include ], [signal(SIGFPE,SIG_IGN)], - [AC_DEFINE(MUST_DISABLE_SIGFPE) - PERLFLAGS="CCFLAGS=-DMUST_DISABLE_SIGFPE"], - AC_MSG_ERROR([ + [CFLAGS="$_cflags -OPT:IEEE_NaN_inf=ON" + AC_IEEE([with the -OPT:IEEE_NaN_inf=ON switch], ieeenaninfswitch, , , , + [CFLAGS="$_cflags -OPT:IEEE_comparisons=ON" + AC_IEEE([with the -OPT:IEEE_comparisons=ON switch], ieeecmpswitch, , , , + [CFLAGS=$_cflags + AC_IEEE([with fpsetmask(0)], mask, + [#include ], [fpsetmask(0)], + [AC_DEFINE(MUST_DISABLE_FPMASK) + PERLFLAGS="CCFLAGS=-DMUST_DISABLE_FPMASK"], + [AC_IEEE([with signal(SIGFPE,SIG_IGN)], sigfpe, + [#include ], [signal(SIGFPE,SIG_IGN)], + [AC_DEFINE(MUST_DISABLE_SIGFPE) + PERLFLAGS="CCFLAGS=-DMUST_DISABLE_SIGFPE"], + AC_MSG_ERROR([ Your Compiler does not do propper IEEE math ... Please find out how to make IEEE math work with your compiler and let me know (oetiker@ee.ethz.ch). Check config.log to see what went wrong ... -]))])])])])])])])]) +]))])])])])])])])])]) AC_CONFIG_FILES([examples/shared-demo.pl \