From: Andreas Schwab Date: Tue, 20 Nov 2007 23:06:39 +0000 (+0000) Subject: Always include when checking for X-Git-Tag: emacs-pretest-23.0.90~9609 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c0a3f2a24a3a4b8241c0aec2f9fc32c4e5e55367;p=emacs.git Always include when checking for res_init. --- diff --git a/configure.in b/configure.in index 12b1347b6d0..930129bfdaf 100644 --- a/configure.in +++ b/configure.in @@ -2756,15 +2756,19 @@ AC_CHECK_LIB(ncurses, tparm) # Do we have res_init, for detecting changes in /etc/resolv.conf? resolv=no -AC_CHECK_FUNC(res_init, have_res_init=yes, have_res_init=no) +AC_TRY_LINK([#include +#include +#include ], + [return res_init();], + have_res_init=yes, have_res_init=no) if test "$have_res_init" = no; then OLIBS="$LIBS" LIBS="$LIBS -lresolv" AC_MSG_CHECKING(for res_init with -lresolv) AC_TRY_LINK([#include #include -#include ], - [res_init();], +#include ], + [return res_init();], have_res_init=yes, have_res_init=no) AC_MSG_RESULT($have_res_init) if test "$have_res_init" = yes ; then