add mingw support to libhv (#2015)

pull/2017/head
xpxz 2 years ago committed by GitHub
parent 1b3a26a731
commit 501bfddd11
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      packages/l/libhv/xmake.lua

@ -35,6 +35,9 @@ package("libhv")
add_frameworks("CoreFoundation", "Security")
elseif is_plat("windows") then
add_syslinks("advapi32")
elseif is_plat("mingw") then
add_syslinks("ws2_32")
add_syslinks("pthread")
end
add_deps("cmake")
@ -54,7 +57,7 @@ package("libhv")
end
end)
on_install("windows", "linux", "macosx", "android", "iphoneos", function(package)
on_install("windows", "linux", "macosx", "android", "iphoneos", "mingw", function(package)
local configs = {"-DBUILD_EXAMPLES=OFF", "-DBUILD_UNITTEST=OFF"}
table.insert(configs, "-DBUILD_SHARED=" .. (package:config("shared") and "ON" or "OFF"))
table.insert(configs, "-DBUILD_STATIC=" .. (package:config("shared") and "OFF" or "ON"))

Loading…
Cancel
Save