|
@@ -6,6 +6,7 @@ package("libwebsockets")
|
|
|
set_urls("https://github.com/warmcat/libwebsockets/archive/refs/tags/$(version).tar.gz",
|
|
|
"https://github.com/warmcat/libwebsockets.git")
|
|
|
|
|
|
+ add_versions("v4.3.4", "896b36aa063b4d05865f9ffee4404b26d4c2d3e2ba17b0b69f021b615377845e")
|
|
|
add_versions("v4.3.3", "6fd33527b410a37ebc91bb64ca51bdabab12b076bc99d153d7c5dd405e4bdf90")
|
|
|
|
|
|
add_deps("cmake")
|
|
@@ -57,7 +58,12 @@ package("libwebsockets")
|
|
|
io.replace("CMakeLists.txt", [[CHECK_LIBRARY_EXISTS(cap cap_set_flag "" LWS_HAVE_LIBCAP)]], "", {plain = true})
|
|
|
end
|
|
|
|
|
|
- local configs = {"-DDISABLE_WERROR=ON", "-DLWS_WITH_MINIMAL_EXAMPLES=OFF", "-DLWS_WITHOUT_TESTAPPS=ON"}
|
|
|
+ local configs = {
|
|
|
+ "-DDISABLE_WERROR=ON",
|
|
|
+ "-DLWS_WITH_MINIMAL_EXAMPLES=OFF",
|
|
|
+ "-DLWS_WITHOUT_TESTAPPS=ON",
|
|
|
+ "-DCMAKE_POLICY_DEFAULT_CMP0057=NEW",
|
|
|
+ }
|
|
|
table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:is_debug() and "Debug" or "Release"))
|
|
|
table.insert(configs, "-DBUILD_SHARED_LIBS=" .. (package:config("shared") and "ON" or "OFF"))
|
|
|
table.insert(configs, "-DLWS_WITH_STATIC=" .. (package:config("shared") and "OFF" or "ON"))
|
|
@@ -69,8 +75,6 @@ package("libwebsockets")
|
|
|
table.insert(configs, "-DLWS_WITH_LIBUV=" .. (package:config("libuv") and "ON" or "OFF"))
|
|
|
table.insert(configs, "-DLWS_WITH_LIBEVENT=" .. (package:config("libevent") and "ON" or "OFF"))
|
|
|
table.insert(configs, "-DLWS_WITH_GLIB=" .. (package:config("glib") and "ON" or "OFF"))
|
|
|
-
|
|
|
- os.mkdir(path.join(package:buildir(), "lib", "pdb"))
|
|
|
import("package.tools.cmake").install(package, configs)
|
|
|
end)
|
|
|
|