diff -Nur -x '*.orig' -x '*~' evolution-exchange-2.32.0//m4/evo_ldap_check.m4 evolution-exchange-2.32.0.new//m4/evo_ldap_check.m4
--- evolution-exchange-2.32.0//m4/evo_ldap_check.m4	2010-09-13 08:19:41.000000000 -0400
+++ evolution-exchange-2.32.0.new//m4/evo_ldap_check.m4	2010-11-03 16:06:18.205064001 -0400
@@ -55,7 +55,7 @@
 			AC_MSG_ERROR([evolution requires OpenLDAP version >= 2])
 		fi
 
-		AC_CHECK_LIB(resolv, res_query, [LDAP_LIBS="-lresolv"])
+		AC_CHECK_LIB(resolv, res_query, [LDAP_LIBS="-lresolv"], AC_CHECK_LIB(resolv, __res_query))
 		AC_CHECK_LIB(socket, bind, [LDAP_LIBS="$LDAP_LIBS -lsocket"])
 		AC_CHECK_LIB(nsl, gethostbyaddr, [LDAP_LIBS="$LDAP_LIBS -lnsl"])
 		AC_CHECK_LIB(lber, ber_get_tag, [
diff -Nur -x '*.orig' -x '*~' evolution-exchange-2.32.0//m4/evo_sunldap_check.m4 evolution-exchange-2.32.0.new//m4/evo_sunldap_check.m4
--- evolution-exchange-2.32.0//m4/evo_sunldap_check.m4	2010-09-13 08:19:41.000000000 -0400
+++ evolution-exchange-2.32.0.new//m4/evo_sunldap_check.m4	2010-11-03 16:06:37.815064001 -0400
@@ -57,7 +57,7 @@
 		       AC_MSG_ERROR([evolution requires SunLDAP version >= 2])
 		fi
 
-		AC_CHECK_LIB(resolv, res_query, [LDAP_LIBS="-lresolv"])
+		AC_CHECK_LIB(resolv, res_query, [LDAP_LIBS="-lresolv"], AC_CHECK_LIB(resolv, __res_query))
 		AC_CHECK_LIB(socket, bind, [LDAP_LIBS="$LDAP_LIBS -lsocket"])
 		AC_CHECK_LIB(nsl, gethostbyaddr, [LDAP_LIBS="$LDAP_LIBS -lnsl"])
 		AC_CHECK_LIB(ldap, ldap_open, [
