From: Harlan Stenn Date: Thu, 28 Jul 2011 06:59:20 +0000 (-0400) Subject: Backport if_nametoindex() check for hpux X-Git-Tag: NTP_4_2_6P4_RC2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=452e84cd3e4468390c81c6a3bd2a476ac2211748;p=thirdparty%2Fntp.git Backport if_nametoindex() check for hpux bk: 4e3108c8B24jE604vjT1r0Pa0yOeLQ --- diff --git a/ChangeLog b/ChangeLog index de9ae7a54..10325d05b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -7,6 +7,7 @@ * [Bug 1975] libntp/mktime.c won't work with 64-bit time_t * [Bug 1978] [Bug 1134] fix in 4.2.6p4-RC1 doesn't build on older Linux. * Backport several fixes for Coverity warnings from ntp-dev. +* Backport if_nametoindex() check for hpux. --- (4.2.6p4-RC1) 2011/07/10 Released by Harlan Stenn diff --git a/configure.ac b/configure.ac index 99b009183..b2d6082bc 100644 --- a/configure.ac +++ b/configure.ac @@ -1577,21 +1577,15 @@ esac]) # # Check for if_nametoindex() for IPv6 scoped addresses support # -AC_CHECK_FUNCS([if_nametoindex]) -case "$ac_cv_func_if_nametoindex" in - no) - case "$host" in - *-hp-hpux*) - AC_CHECK_LIB([ipv6], [if_nametoindex], - [ac_cv_func_if_nametoindex=yes ; LIBS="-lipv6 $LIBS"]) - ;; - esac +case "$host" in + *-hp-hpux*) + AC_SEARCH_LIBS([if_nametoindex], [ipv6]) esac +AC_CHECK_FUNCS([if_nametoindex]) case "$ac_cv_func_if_nametoindex" in yes) AC_DEFINE([ISC_PLATFORM_HAVEIFNAMETOINDEX], [1], [ISC: do we have if_nametoindex()?]) - ;; esac AC_SEARCH_LIBS([inet_ntop], [resolv], , , [-lsocket -lnsl])