tweaks for error handling

This commit is contained in:
David MacKenzie 1994-08-27 01:27:32 +00:00
parent 0e89006bb4
commit 479d6ceeb0
6 changed files with 36 additions and 36 deletions

View File

@ -1125,8 +1125,8 @@ cat > conftest.${ac_ext} <<EOF
#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
@ -1219,8 +1219,9 @@ ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
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

View File

@ -854,7 +854,8 @@ 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,

View File

@ -1913,13 +1913,11 @@ prints @samp{checking for @var{echo-text}} to the standard output first.
@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
@ -1946,12 +1944,12 @@ your programs.
@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

View File

@ -1913,13 +1913,11 @@ prints @samp{checking for @var{echo-text}} to the standard output first.
@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
@ -1946,12 +1944,12 @@ your programs.
@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

View File

@ -1125,8 +1125,8 @@ cat > conftest.${ac_ext} <<EOF
#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
@ -1219,8 +1219,9 @@ ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
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

View File

@ -854,7 +854,8 @@ 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,