]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
cmake: assume `wldap32` availability on Windows
authorViktor Szakats <commit@vsz.me>
Tue, 8 Aug 2023 09:41:20 +0000 (09:41 +0000)
committerViktor Szakats <commit@vsz.me>
Wed, 9 Aug 2023 12:01:07 +0000 (12:01 +0000)
This system library first shipped with Windows ME, available as an extra
install for some older releases (according to [1]). The import library
was present already in old MinGW 3.4.2 (year 2007).

Drop the feature check and its associated `HAVE_WLDAP32` variable.

To manually disable `wldap32`, you can use the `USE_WIN32_LDAP=OFF`
CMake option, like before.

[1]: https://dlcdn.apache.org/httpd/binaries/win32/LEGACY.html

Reviewed-by: Jay Satiro
Closes #11624

CMakeLists.txt

index 5b2427d4f32a10e63d1eee8d32bdb001d65f91c6..e60fbd5b84983dd1cc0493bfcbed7940c914fc1f 100644 (file)
@@ -680,10 +680,8 @@ if(NOT CURL_DISABLE_LDAP)
   if(WIN32)
     option(USE_WIN32_LDAP "Use Windows LDAP implementation" ON)
     if(USE_WIN32_LDAP)
-      check_library_exists_concat("wldap32" cldap_open HAVE_WLDAP32)
-      if(NOT HAVE_WLDAP32)
-        set(USE_WIN32_LDAP OFF)
-      elseif(NOT CURL_DISABLE_LDAPS)
+      list(APPEND CURL_LIBS "wldap32")
+      if(NOT CURL_DISABLE_LDAPS)
         set(HAVE_LDAP_SSL ON)
       endif()
     endif()