summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorFridrich Strba <fridrich.strba@bluewin.ch>2012-07-09 01:38:48 -0600
committerFridrich Štrba <fridrich.strba@bluewin.ch>2012-07-09 09:44:37 +0200
commit4bc7149816e51e6ccca7673876586f8dc9a2c3d0 (patch)
treeb3a5f20f63aa131728f93955ed1ed9c7b23a64b7 /extensions
parent9c8dc01d3a40ec905c9d816c733ceb5d621e0426 (diff)
Trying to use Windows LDAP for Windows builds
Change-Id: Ic06bda1393de4da05af01f79b8ba54cf0ee2cb73 Signed-off-by: Fridrich Štrba <fridrich.strba@bluewin.ch>
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/config/ldap/ldapaccess.cxx2
-rw-r--r--extensions/source/config/ldap/wrapldapinclude.hxx14
2 files changed, 15 insertions, 1 deletions
diff --git a/extensions/source/config/ldap/ldapaccess.cxx b/extensions/source/config/ldap/ldapaccess.cxx
index c1d07ed3ab8a..00e62d9eb2df 100644
--- a/extensions/source/config/ldap/ldapaccess.cxx
+++ b/extensions/source/config/ldap/ldapaccess.cxx
@@ -283,7 +283,7 @@ void LdapConnection::loadModule()
{
#if defined WNT
s_Ldap_Module = osl_loadModuleRelativeAscii(
- &thisModule, "nsldap32v50.dll", 0);
+ &thisModule, "wldap32.dll", 0);
#elif defined WITH_OPENLDAP
s_Ldap_Module = osl_loadModuleAscii(
("libldap-" SAL_STRINGIFY(LDAP_VENDOR_VERSION_MAJOR) "."
diff --git a/extensions/source/config/ldap/wrapldapinclude.hxx b/extensions/source/config/ldap/wrapldapinclude.hxx
index 470d4b9c6ac9..1b84b76e246d 100644
--- a/extensions/source/config/ldap/wrapldapinclude.hxx
+++ b/extensions/source/config/ldap/wrapldapinclude.hxx
@@ -31,10 +31,24 @@
# define LDAP_CALL
#endif
#else
+#ifdef WNT
+#include <windows.h>
+#include <winldap.h>
+#ifndef LDAP_API
+# define LDAP_API(rt) rt
+#endif
+#ifndef LDAP_CALL
+# define LDAP_CALL
+#endif
+#ifndef LDAP_NO_ATTRS
+# define LDAP_NO_ATTRS "1.1"
+#endif
+#else // !defined WNT
#ifndef LDAP_INCLUDED
#define LDAP_INCLUDED
#include <ldap/ldap.h>
#endif // LDAP_INCLUDED
+#endif // WNT
#endif
#ifdef WNT