Index: m4/ldap.m4 =================================================================== --- m4/ldap.m4 +++ m4/ldap.m4 @@ -46,14 +46,14 @@ #else #include #endif -],[ldap_open("foobar",1234);], +],[ldap_open("foobar",1234);ber_alloc();], [gnupg_cv_func_ldap_init=yes],[gnupg_cv_func_ldap_init=no]) AC_MSG_RESULT([$gnupg_cv_func_ldap_init]) if test $gnupg_cv_func_ldap_init = no; then AC_MSG_CHECKING([whether I can make LDAP be sane with lber.h]) AC_TRY_LINK([#include -#include ],[ldap_open("foobar",1234);], +#include ],[ldap_open("foobar",1234);ber_alloc();], [gnupg_cv_func_ldaplber_init=yes],[gnupg_cv_func_ldaplber_init=no]) AC_MSG_RESULT([$gnupg_cv_func_ldaplber_init]) fi