blob: 81a187751f0c6700259ca846d4891b4ec905254f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
From: NIIBE Yutaka <gniibe@fsij.org>
Date: Thu, 15 Sep 2022 11:21:28 +0900
Subject: [PATCH] build: Use LDAP_DEPRECATED to detect ldap library.
* m4/ldap.m4: Define LDAP_DEPRECATED when test.
--
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
(cherry picked from commit ddc6f7d194918791ac9dff0e5af4b80933189afd)
---
m4/ldap.m4 | 2 ++
1 file changed, 2 insertions(+)
diff --git a/m4/ldap.m4 b/m4/ldap.m4
index 954f88a..f65eed5 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_TRY_LINK([#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])
|