Replace custom HAVE_CATGETS define with AC_CHECK_FUNCS call

This commit is contained in:
Ondřej Surý 2018-09-05 13:34:44 +02:00
parent 78bb5761a0
commit 7384a9f23a
4 changed files with 11 additions and 9 deletions

View file

@ -17,9 +17,6 @@
***/
@TOP@
/** define if catgets() is available */
#undef HAVE_CATGETS
/** define if getifaddrs() exists */
#undef HAVE_GETIFADDRS

View file

@ -17,9 +17,6 @@
*** it does not get installed.
***/
/** define if catgets() is available */
#undef HAVE_CATGETS
/** define if getifaddrs() exists */
#undef HAVE_GETIFADDRS
@ -122,6 +119,9 @@
/* Define to 1 if the compiler supports __builtin_expect. */
#undef HAVE_BUILTIN_EXPECT
/* Define to 1 if you have the `catgets' function. */
#undef HAVE_CATGETS
/* Define to 1 if you have the `chroot' function. */
#undef HAVE_CHROOT

9
configure vendored
View file

@ -17071,11 +17071,16 @@ fi
#
# NLS
#
ac_fn_c_check_func "$LINENO" "catgets" "ac_cv_func_catgets"
for ac_func in catgets
do :
ac_fn_c_check_func "$LINENO" "catgets" "ac_cv_func_catgets"
if test "x$ac_cv_func_catgets" = xyes; then :
$as_echo "#define HAVE_CATGETS 1" >>confdefs.h
cat >>confdefs.h <<_ACEOF
#define HAVE_CATGETS 1
_ACEOF
fi
done
#

View file

@ -1603,7 +1603,7 @@ AC_SUBST(MKDEPPROG)
#
# NLS
#
AC_CHECK_FUNC(catgets, AC_DEFINE(HAVE_CATGETS),)
AC_CHECK_FUNCS([catgets])
#
# -lxnet buys us one big porting headache... standards, gotta love 'em.