mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-21 07:09:34 -05:00
Check for netinet/tcp.h
Update res_search check and place behind --enable-dns.
This commit is contained in:
parent
04c5711506
commit
b738f2a4db
2 changed files with 20 additions and 10 deletions
27
configure.in
27
configure.in
|
|
@ -544,19 +544,25 @@ dnl
|
|||
AC_CHECK_LIB(gen, main)
|
||||
])
|
||||
|
||||
if test $ol_enable_dns != no ; then
|
||||
dnl Check for resolver routines
|
||||
AC_CHECK_FUNCS(res_search)
|
||||
if test $ac_cv_func_res_search = "no" ; then
|
||||
AC_CHECK_FUNC(res_search,:)
|
||||
if test $ac_cv_func_res_search = no ; then
|
||||
AC_CHECK_LIB(bind, res_search)
|
||||
if test "$ac_cv_lib_bind_res_search" = "yes" ; then
|
||||
AC_DEFINE(HAVE_RES_SEARCH,1,
|
||||
[define if you have res_search()])
|
||||
else
|
||||
AC_CHECK_LIB(resolv, res_search)
|
||||
if test "$ac_cv_lib_resolv_res_search" = "yes" ; then
|
||||
AC_DEFINE(HAVE_RES_SEARCH,1,
|
||||
[define if you have res_search()])
|
||||
ac_cv_func_res_search=$ac_cv_lib_bind_res_search
|
||||
fi
|
||||
if test $ac_cv_func_res_search = no ; then
|
||||
AC_CHECK_LIB(resolv, res_search)
|
||||
ac_cv_func_res_search=$ac_cv_lib_resolv_res_search
|
||||
fi
|
||||
|
||||
if test "$ac_cv_func_res_search" = yes ; then
|
||||
AC_DEFINE(HAVE_RES_SEARCH,1,
|
||||
[define if you have res_search()])
|
||||
elif test $ol_enable_dns = yes ; then
|
||||
AC_MSG_ERROR([--enable-dns requires res_search])
|
||||
else
|
||||
AC_MSG_WARN([no res_search, disabling DNS support])
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
@ -1654,6 +1660,7 @@ AC_CHECK_HEADERS( \
|
|||
libutil.h \
|
||||
limits.h \
|
||||
locale.h \
|
||||
netinet/tcp.h \
|
||||
malloc.h \
|
||||
memory.h \
|
||||
psap.h \
|
||||
|
|
|
|||
|
|
@ -26,7 +26,10 @@
|
|||
#endif
|
||||
|
||||
#include <netinet/in.h>
|
||||
|
||||
#ifdef HAVE_NETINET_TCP_H
|
||||
#include <netinet/tcp.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_ARPA_INET_H
|
||||
#include <arpa/inet.h>
|
||||
|
|
|
|||
Loading…
Reference in a new issue