diff --git a/ChangeLog b/ChangeLog index 419c7ae..3b0ac75 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2009-10-14 Paolo Bonzini + + * configure.ac: Use cache variables rather than AC_CHECK_FUNC. + 2009-10-14 Paolo Bonzini * configure.ac: Remove obselete configure tests. diff --git a/configure.ac b/configure.ac index 01e5542..9a400be 100644 --- a/configure.ac +++ b/configure.ac @@ -51,22 +51,20 @@ AC_TYPE_SIZE_T AM_GNU_GETTEXT_VERSION(0.17) AM_GNU_GETTEXT([external]) -AC_CHECK_FUNCS_ONCE(isatty isascii memcpy strchr strtoul +AC_CHECK_FUNCS_ONCE(isatty isascii memcpy strchr strtoul lstat readlink popen pathconf fchown fchmod setlocale) +# Check whether we are able to follow symlinks +if test "$ac_cv_func_lstat:$ac_cv_func_readlink" = yes:yes; then + AC_DEFINE(ENABLE_FOLLOW_SYMLINKS, ,[Follow symlinks when processing in place]) +fi + AC_ARG_ENABLE(pcregrep, [ --enable-pcregrep build the pcregrep test program], PCREGREP=pcregrep, PCREGREP=) AC_SUBST(PCREGREP) -# Check whether we are able to follow symlinks -AC_CHECK_FUNC(lstat, have_lstat=yes) -AC_CHECK_FUNC(readlink, have_readlink=yes) -if test "x$have_lstat" = xyes -a "x$have_readlink" = xyes; then - AC_DEFINE(ENABLE_FOLLOW_SYMLINKS, ,[Follow symlinks when processing in place]) -fi - # Under MinGW, the bsd.sh test fails because of the EOF character (^Z). case $host in *mingw*) XFAIL_TESTS="$XFAIL_TESTS bsd" ;;