]> granicus.if.org Git - curl/commitdiff
cmake: don't require OpenSSL if USE_OPENSSL=OFF
authorslodki <slodki@users.noreply.github.com>
Sat, 15 Sep 2018 23:15:08 +0000 (01:15 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 18 Sep 2018 14:34:23 +0000 (16:34 +0200)
User must have OpenSSL installed even if not used by libcurl at all
since 7.61.1 release.  Broken at
7867aaa9a01decf93711428462335be8cef70212

Reviewed-by: Sergei Nikulov
Closes #3001

CMake/curl-config.cmake.in

index 73e04c606efb76271defeca176f00e23ff727533..40c1288e15465be6110a69b830471b54b336f007 100644 (file)
@@ -9,8 +9,8 @@ if(NOT CURL_FIND_COMPONENTS)
   endif()
 endif()
 
-include(CMakeFindDependencyMacro)
-if(CURL_FIND_REQUIRED_libcurl)
+if("@USE_OPENSSL@")
+    include(CMakeFindDependencyMacro)
     find_dependency(OpenSSL "@OPENSSL_VERSION_MAJOR@")
 endif()