#include "confdefs.h"
[$2]
EOF
-eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1"
-if egrep "$1" conftest.out >/dev/null 2>&1; then
+if eval "$ac_cpp conftest.${ac_ext}" 2>&AC_FD_CC |
+ egrep "$1" >/dev/null 2>&1; then
ifelse([$3], , :, [rm -rf conftest*
$3])
ifelse([$4], , , [else
if test -z "$ac_err"; then
ifelse([$2], , :, [rm -rf conftest*
$2])
-ifelse([$3], , , [else
- rm -rf conftest*
+else
+ echo "$ac_err" >&AC_FD_CC
+ifelse([$3], , , [ rm -rf conftest*
$3
])dnl
fi
])dnl
dnl
AC_DEFUN(AC_FUNC_ALLOCA,
-[# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
+[AC_REQUIRE_CPP()dnl Set CPP; we run AC_EGREP_CPP conditionally.
+# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
AC_MSG_CHECKING([for working alloca.h])
AC_CACHE_VAL(ac_cv_header_alloca_h,
@defmac AC_EGREP_CPP (@var{pattern}, @var{program}, @var{action-if-found} @r{[}, @var{action-if-not-found}@r{]})
@maindex EGREP_CPP
-@var{program} is the text of a C or C++ program, on which shell variable and
-backquote substitutions are performed. If the output of running the
-preprocessor on @var{program} contains the @code{egrep} regular
-expression @var{pattern}, execute shell commands @var{action-if-found},
-otherwise execute @var{action-if-not-found}. (It is an unfortunate
-oversight that we use the word @code{PROGRAM} in Autoconf macro names to
-sometimes mean C or C++ source code and sometimes mean a UNIX command.)
+@var{program} is the text of a C or C++ program, on which shell
+variable, backquote, and backslash substitutions are performed. If the
+output of running the preprocessor on @var{program} contains the
+@code{egrep} regular expression @var{pattern}, execute shell commands
+@var{action-if-found}, otherwise execute @var{action-if-not-found}.
This macro calls @code{AC_PROG_CPP} or @code{AC_PROG_CXXCPP} (depending
on which language is current, @pxref{Language Choice}), if it hasn't
@defmac AC_TRY_CPP (@var{includes}, @var{action-if-true} @r{[}, @var{action-if-false}@r{]})
@maindex TRY_CPP
-@var{includes} is C or C++ @code{#include} statements and declarations, on
-which shell variable and backquote substitutions are performed.
-(Actually, it can be any C program, but other statements are probably
-not useful.) If the preprocessor produces no error messages while
-processing it, run shell commands @var{action-if-true}. Otherwise run
-shell commands @var{action-if-false}.
+@var{includes} is C or C++ @code{#include} statements and declarations,
+on which shell variable, backquote, and backslash substitutions are
+performed. (Actually, it can be any C program, but other statements are
+probably not useful.) If the preprocessor produces no error messages
+while processing it, run shell commands @var{action-if-true}. Otherwise
+run shell commands @var{action-if-false}.
This macro calls @code{AC_PROG_CPP} or @code{AC_PROG_CXXCPP} (depending
on which language is current, @pxref{Language Choice}), if it hasn't
@defmac AC_EGREP_CPP (@var{pattern}, @var{program}, @var{action-if-found} @r{[}, @var{action-if-not-found}@r{]})
@maindex EGREP_CPP
-@var{program} is the text of a C or C++ program, on which shell variable and
-backquote substitutions are performed. If the output of running the
-preprocessor on @var{program} contains the @code{egrep} regular
-expression @var{pattern}, execute shell commands @var{action-if-found},
-otherwise execute @var{action-if-not-found}. (It is an unfortunate
-oversight that we use the word @code{PROGRAM} in Autoconf macro names to
-sometimes mean C or C++ source code and sometimes mean a UNIX command.)
+@var{program} is the text of a C or C++ program, on which shell
+variable, backquote, and backslash substitutions are performed. If the
+output of running the preprocessor on @var{program} contains the
+@code{egrep} regular expression @var{pattern}, execute shell commands
+@var{action-if-found}, otherwise execute @var{action-if-not-found}.
This macro calls @code{AC_PROG_CPP} or @code{AC_PROG_CXXCPP} (depending
on which language is current, @pxref{Language Choice}), if it hasn't
@defmac AC_TRY_CPP (@var{includes}, @var{action-if-true} @r{[}, @var{action-if-false}@r{]})
@maindex TRY_CPP
-@var{includes} is C or C++ @code{#include} statements and declarations, on
-which shell variable and backquote substitutions are performed.
-(Actually, it can be any C program, but other statements are probably
-not useful.) If the preprocessor produces no error messages while
-processing it, run shell commands @var{action-if-true}. Otherwise run
-shell commands @var{action-if-false}.
+@var{includes} is C or C++ @code{#include} statements and declarations,
+on which shell variable, backquote, and backslash substitutions are
+performed. (Actually, it can be any C program, but other statements are
+probably not useful.) If the preprocessor produces no error messages
+while processing it, run shell commands @var{action-if-true}. Otherwise
+run shell commands @var{action-if-false}.
This macro calls @code{AC_PROG_CPP} or @code{AC_PROG_CXXCPP} (depending
on which language is current, @pxref{Language Choice}), if it hasn't
#include "confdefs.h"
[$2]
EOF
-eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1"
-if egrep "$1" conftest.out >/dev/null 2>&1; then
+if eval "$ac_cpp conftest.${ac_ext}" 2>&AC_FD_CC |
+ egrep "$1" >/dev/null 2>&1; then
ifelse([$3], , :, [rm -rf conftest*
$3])
ifelse([$4], , , [else
if test -z "$ac_err"; then
ifelse([$2], , :, [rm -rf conftest*
$2])
-ifelse([$3], , , [else
- rm -rf conftest*
+else
+ echo "$ac_err" >&AC_FD_CC
+ifelse([$3], , , [ rm -rf conftest*
$3
])dnl
fi
])dnl
dnl
AC_DEFUN(AC_FUNC_ALLOCA,
-[# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
+[AC_REQUIRE_CPP()dnl Set CPP; we run AC_EGREP_CPP conditionally.
+# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
AC_MSG_CHECKING([for working alloca.h])
AC_CACHE_VAL(ac_cv_header_alloca_h,