Parcourir la source

libcurl: Restore openssl by default on Linux/Android (#5970)

* libcurl: Restore openssl by default on Linux/Android

See https://github.com/xmake-io/xmake-repo/pull/5892

* Update xmake.lua
Jérôme Leclercq il y a 8 mois
Parent
commit
594cd872bc
1 fichiers modifiés avec 7 ajouts et 0 suppressions
  1. 7 0
      packages/l/libcurl/xmake.lua

+ 7 - 0
packages/l/libcurl/xmake.lua

@@ -38,6 +38,13 @@ package("libcurl")
 
     -- we init all configurations in on_load, because package("curl") need it.
     on_load(function (package)
+        if package:is_plat("linux", "android", "cross") then
+            -- if no TLS backend has been enabled nor disabled, enable openssl by default
+            if package:config("openssl") == nil and package:config("openssl3") == nil and package:config("mbedtls") == nil then
+                package:config_set("openssl", true)
+            end
+        end
+
         assert(not (package:config("openssl") and package:config("openssl3")), "OpenSSL and OpenSSL-3 cannot be enabled at the same time.")
 
         if package:is_plat("macosx", "iphoneos") then