- pick up -lresolv on systems with glibc 2.2.4 (needed by openldap 2.x)

git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@390 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
okir 2002-03-25 10:19:57 +00:00
parent 0356c03637
commit 262b1d79d9
1 changed files with 10 additions and 0 deletions

View File

@ -354,6 +354,16 @@ if test "x$LIBRESOLV" = "x"; then
LIBS="$t_oldLibs"
fi
if test "x$LIBRESOLV" = "x"; then
# glibc 2.2.4 and libresolv is difficult
# - gethostbyname won't require lresolv because all
# queries are made through the nsswitch
# - checking for the variable _res will not require
# lresolv because _res is defined somewhere
AC_CHECK_LIB(resolv, res_query, [LIBRESOLV=-lresolv])
LIBS="$t_oldLibs"
fi
# See about the routines that possibly exist at the libraries..
LIBS="$t_oldLibs $LIBSOCKET"
AC_CHECK_FUNCS(socket socketpair)