In the previous patch, if you use:
# AC_LANG_FUNC_LINK_TRY(C)(PROLOGUE, FUNCTION)
# --------------------------------------------
# Don't include <ctype.h> because on OSF/1 3.0 it includes
# <sys/types.h> which includes <sys/select.h> which contains a
# prototype for select. Similarly for bzero.
define([AC_LANG_FUNC_LINK_TRY(C)],
[AC_LANG_PROGRAM(
[/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $2 (); below. */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
/* char $2 ();*/
$1
],
[/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$2) || defined (__stub___$2)
choke me
#else
return !$2;
#endif
])])
them the configuration of the fileutils goes almost smooth, but fails,
of course, as soon as it AC_CHECK_FUNC a function which is not
declared in the default includes.
Maybe we should AC_CHECK_DECL each function we AC_CHECK?