aboutsummaryrefslogtreecommitdiffstats
path: root/m4
diff options
context:
space:
mode:
authorNIIBE Yutaka <[email protected]>2022-09-15 02:21:28 +0000
committerNIIBE Yutaka <[email protected]>2022-09-15 02:21:28 +0000
commitddc6f7d194918791ac9dff0e5af4b80933189afd (patch)
tree04da3e11e13cdf5dfc56e31c41a8827a02f158c6 /m4
parentbuild: Update .gitignore for translations under po/. (diff)
downloadgnupg-ddc6f7d194918791ac9dff0e5af4b80933189afd.tar.gz
gnupg-ddc6f7d194918791ac9dff0e5af4b80933189afd.zip
build: Use LDAP_DEPRECATED to detect ldap library.
* m4/ldap.m4: Define LDAP_DEPRECATED when test. -- Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'm4')
-rw-r--r--m4/ldap.m42
1 files changed, 2 insertions, 0 deletions
diff --git a/m4/ldap.m4 b/m4/ldap.m4
index f92bc3ce3..92dcf8b03 100644
--- a/m4/ldap.m4
+++ b/m4/ldap.m4
@@ -44,6 +44,7 @@ if test x$_ldap_with != xno ; then
#include <winsock2.h>
#include <winldap.h>
#else
+#define LDAP_DEPRECATED 1
#include <ldap.h>
#endif
]],[[ldap_open("foobar",1234);]])],
@@ -53,6 +54,7 @@ if test x$_ldap_with != xno ; then
if test $gnupg_cv_func_ldap_init = no; then
AC_MSG_CHECKING([whether I can make LDAP be sane with lber.h])
AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <lber.h>
+#define LDAP_DEPRECATED 1
#include <ldap.h>]],[[ldap_open("foobar",1234);]])],
[gnupg_cv_func_ldaplber_init=yes],[gnupg_cv_func_ldaplber_init=no])
AC_MSG_RESULT([$gnupg_cv_func_ldaplber_init])