From 23693a38979a5f30334176bd3ddd1c42004f55b2 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Mon, 24 Jan 2000 12:06:01 +0000 Subject: [PATCH] add int endnetent test --- configure | 133 ++++++++++++++++++++++++++++++--------------------- configure.in | 12 ++++- 2 files changed, 90 insertions(+), 55 deletions(-) diff --git a/configure b/configure index b0ec4ed7f7..356a8bbb98 100755 --- a/configure +++ b/configure @@ -2302,19 +2302,44 @@ fi rm -f conftest* -echo $ac_n "checking for gethostbyadd(const void *, size_t, ...)""... $ac_c" 1>&6 -echo "configure:2307: checking for gethostbyadd(const void *, size_t, ...)" >&5 +echo $ac_n "checking for int endnetent""... $ac_c" 1>&6 +echo "configure:2307: checking for int endnetent" >&5 cat > conftest.$ac_ext < +int main() { +int i = endnetent(); return(0); +; return 0; } +EOF +if { (eval echo configure:2317: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + echo "$ac_t""yes" 1>&6 + ISC_LWRES_ENDNETENTINT="#define ISC_LWRES_ENDNETENTINT 1" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""no" 1>&6 + ISC_LWRES_ENDNETENTINT="#undef ISC_LWRES_ENDNETENTINT" +fi +rm -f conftest* + + +echo $ac_n "checking for gethostbyadd(const void *, size_t, ...)""... $ac_c" 1>&6 +echo "configure:2332: checking for gethostbyadd(const void *, size_t, ...)" >&5 +cat > conftest.$ac_ext < struct hostent *gethostbyaddr(const void *, size_t, int); int main() { return(0); ; return 0; } EOF -if { (eval echo configure:2318: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2343: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 ISC_LWRES_GETHOSTBYADDRVOID="#define ISC_LWRES_GETHOSTBYADDRVOID 1" @@ -2329,9 +2354,9 @@ rm -f conftest* echo $ac_n "checking for h_errno in netdb.h""... $ac_c" 1>&6 -echo "configure:2333: checking for h_errno in netdb.h" >&5 +echo "configure:2358: checking for h_errno in netdb.h" >&5 cat > conftest.$ac_ext < @@ -2339,7 +2364,7 @@ int main() { h_errno = 1; return(0); ; return 0; } EOF -if { (eval echo configure:2343: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2368: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 ISC_LWRES_NEEDHERRNO="#undef ISC_LWRES_NEEDHERRNO" @@ -2354,12 +2379,12 @@ rm -f conftest* echo $ac_n "checking for getipnodebyname""... $ac_c" 1>&6 -echo "configure:2358: checking for getipnodebyname" >&5 +echo "configure:2383: checking for getipnodebyname" >&5 if eval "test \"`echo '$''{'ac_cv_func_getipnodebyname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_getipnodebyname=yes" else @@ -2403,12 +2428,12 @@ ISC_LWRES_GETIPNODEPROTO="#define ISC_LWRES_GETIPNODEPROTO 1" fi echo $ac_n "checking for getnameinfo""... $ac_c" 1>&6 -echo "configure:2407: checking for getnameinfo" >&5 +echo "configure:2432: checking for getnameinfo" >&5 if eval "test \"`echo '$''{'ac_cv_func_getnameinfo'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_getnameinfo=yes" else @@ -2452,12 +2477,12 @@ ISC_LWRES_GETNAMEINFOPROTO="#define ISC_LWRES_GETNAMEINFOPROTO 1" fi echo $ac_n "checking for getaddrinfo""... $ac_c" 1>&6 -echo "configure:2456: checking for getaddrinfo" >&5 +echo "configure:2481: checking for getaddrinfo" >&5 if eval "test \"`echo '$''{'ac_cv_func_getaddrinfo'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_getaddrinfo=yes" else @@ -2506,9 +2531,9 @@ fi echo $ac_n "checking for interface list sysctl""... $ac_c" 1>&6 -echo "configure:2510: checking for interface list sysctl" >&5 +echo "configure:2535: checking for interface list sysctl" >&5 cat > conftest.$ac_ext < @@ -2615,7 +2640,7 @@ else fi echo $ac_n "checking build system type""... $ac_c" 1>&6 -echo "configure:2619: checking build system type" >&5 +echo "configure:2644: checking build system type" >&5 build_alias=$build case "$build_alias" in @@ -2644,7 +2669,7 @@ ac_prog=ld if test "$ac_cv_prog_gcc" = yes; then # Check if gcc -print-prog-name=ld gives a path. echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6 -echo "configure:2648: checking for ld used by GCC" >&5 +echo "configure:2673: checking for ld used by GCC" >&5 ac_prog=`($CC -print-prog-name=ld) 2>&5` case "$ac_prog" in # Accept absolute paths. @@ -2668,10 +2693,10 @@ echo "configure:2648: checking for ld used by GCC" >&5 esac elif test "$with_gnu_ld" = yes; then echo $ac_n "checking for GNU ld""... $ac_c" 1>&6 -echo "configure:2672: checking for GNU ld" >&5 +echo "configure:2697: checking for GNU ld" >&5 else echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6 -echo "configure:2675: checking for non-GNU ld" >&5 +echo "configure:2700: checking for non-GNU ld" >&5 fi if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2707,7 +2732,7 @@ fi test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; } echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6 -echo "configure:2711: checking if the linker ($LD) is GNU ld" >&5 +echo "configure:2736: checking if the linker ($LD) is GNU ld" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2723,7 +2748,7 @@ echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6 -echo "configure:2727: checking for BSD-compatible nm" >&5 +echo "configure:2752: checking for BSD-compatible nm" >&5 if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2760,7 +2785,7 @@ echo "$ac_t""$NM" 1>&6 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 -echo "configure:2764: checking whether ln -s works" >&5 +echo "configure:2789: checking whether ln -s works" >&5 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2804,8 +2829,8 @@ test x"$silent" = xyes && libtool_flags="$libtool_flags --silent" case "$host" in *-*-irix6*) # Find out which ABI we are using. - echo '#line 2808 "configure"' > conftest.$ac_ext - if { (eval echo configure:2809: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + echo '#line 2833 "configure"' > conftest.$ac_ext + if { (eval echo configure:2834: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then case "`/usr/bin/file conftest.o`" in *32-bit*) LD="${LD-ld} -32" @@ -2826,19 +2851,19 @@ case "$host" in SAVE_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -belf" echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6 -echo "configure:2830: checking whether the C compiler needs -belf" >&5 +echo "configure:2855: checking whether the C compiler needs -belf" >&5 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* lt_cv_cc_needs_belf=yes else @@ -2962,9 +2987,9 @@ fi case "$enable_ipv6" in yes|''|autodetect) echo $ac_n "checking for IPv6 structures""... $ac_c" 1>&6 -echo "configure:2966: checking for IPv6 structures" >&5 +echo "configure:2991: checking for IPv6 structures" >&5 cat > conftest.$ac_ext < @@ -2974,7 +2999,7 @@ int main() { struct sockaddr_in6 sin6; return (0); ; return 0; } EOF -if { (eval echo configure:2978: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3003: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 found_ipv6=yes @@ -3012,7 +3037,7 @@ esac echo $ac_n "checking for Kame IPv6 support""... $ac_c" 1>&6 -echo "configure:3016: checking for Kame IPv6 support" >&5 +echo "configure:3041: checking for Kame IPv6 support" >&5 # Check whether --with-kame or --without-kame was given. if test "${with_kame+set}" = set; then withval="$with_kame" @@ -3054,12 +3079,12 @@ esac echo $ac_n "checking for inet_ntop""... $ac_c" 1>&6 -echo "configure:3058: checking for inet_ntop" >&5 +echo "configure:3083: checking for inet_ntop" >&5 if eval "test \"`echo '$''{'ac_cv_func_inet_ntop'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_inet_ntop=yes" else @@ -3106,12 +3131,12 @@ ISC_EXTRA_OBJS="$ISC_EXTRA_OBJS inet_ntop.$O" fi echo $ac_n "checking for inet_pton""... $ac_c" 1>&6 -echo "configure:3110: checking for inet_pton" >&5 +echo "configure:3135: checking for inet_pton" >&5 if eval "test \"`echo '$''{'ac_cv_func_inet_pton'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_inet_pton=yes" else @@ -3158,12 +3183,12 @@ ISC_EXTRA_OBJS="$ISC_EXTRA_OBJS inet_pton.$O" fi echo $ac_n "checking for inet_aton""... $ac_c" 1>&6 -echo "configure:3162: checking for inet_aton" >&5 +echo "configure:3187: checking for inet_aton" >&5 if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_inet_aton=yes" else @@ -3210,12 +3235,12 @@ ISC_EXTRA_OBJS="$ISC_EXTRA_OBJS inet_aton.$O" fi echo $ac_n "checking for strsep""... $ac_c" 1>&6 -echo "configure:3214: checking for strsep" >&5 +echo "configure:3239: checking for strsep" >&5 if eval "test \"`echo '$''{'ac_cv_func_strsep'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strsep=yes" else @@ -3261,12 +3286,12 @@ ISC_EXTRA_OBJS="$ISC_EXTRA_OBJS strsep.$O" fi echo $ac_n "checking for vsnprintf""... $ac_c" 1>&6 -echo "configure:3265: checking for vsnprintf" >&5 +echo "configure:3290: checking for vsnprintf" >&5 if eval "test \"`echo '$''{'ac_cv_func_vsnprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3318: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_vsnprintf=yes" else @@ -3322,12 +3347,12 @@ fi echo $ac_n "checking for chroot""... $ac_c" 1>&6 -echo "configure:3326: checking for chroot" >&5 +echo "configure:3351: checking for chroot" >&5 if eval "test \"`echo '$''{'ac_cv_func_chroot'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_chroot=yes" else @@ -3376,17 +3401,17 @@ for ac_hdr in linux/capability.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3380: checking for $ac_hdr" >&5 +echo "configure:3405: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3390: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3415: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* diff --git a/configure.in b/configure.in index 9215153ab7..295a09826e 100644 --- a/configure.in +++ b/configure.in @@ -13,7 +13,7 @@ dnl PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS dnl ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS dnl SOFTWARE. -AC_REVISION($Revision: 1.82 $) +AC_REVISION($Revision: 1.83 $) AC_PREREQ(2.13) @@ -351,6 +351,16 @@ AC_TRY_COMPILE([ ISC_LWRES_SETNETENTINT="#undef ISC_LWRES_SETNETENTINT"]) AC_SUBST(ISC_LWRES_SETNETENTINT) +AC_MSG_CHECKING(for int endnetent) +AC_TRY_COMPILE([ +#include ], +[int i = endnetent(); return(0);], + [AC_MSG_RESULT(yes) + ISC_LWRES_ENDNETENTINT="#define ISC_LWRES_ENDNETENTINT 1"], + [AC_MSG_RESULT(no) + ISC_LWRES_ENDNETENTINT="#undef ISC_LWRES_ENDNETENTINT"]) +AC_SUBST(ISC_LWRES_SETNETENTINT) + AC_MSG_CHECKING(for gethostbyadd(const void *, size_t, ...)) AC_TRY_COMPILE([ #include