update libuv and tbb (#2463)

* update libuv

* update tbb

* fix tbb

* fix libuv and tbb

* correct syslinks
pull/2478/head
Hoildkv 2 years ago committed by GitHub
parent 50981b7d2f
commit fa285a3126
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 15
      packages/l/libuv/xmake.lua
  2. 4
      packages/t/tbb/xmake.lua

@ -4,8 +4,9 @@ package("libuv")
set_description("A multi-platform support library with a focus on asynchronous I/O.")
set_license("MIT")
set_urls("https://github.com/libuv/libuv/archive/$(version).zip",
set_urls("https://github.com/libuv/libuv/archive/refs/tags/$(version).zip",
"https://github.com/libuv/libuv.git")
add_versions("v1.46.0", "45953dc9b64db7f4f47561f9e4543b762c52adfe7c9b6f8e9efbc3b4dd7d3081")
add_versions("v1.44.1", "d233a9c522a9f4afec47b0d12f302d93d114a9e3ea104150e65f55fd931518e6")
add_versions("v1.42.0", "031130768b25ae18c4b9d4a94ba7734e2072b11c6fce3e554612c516c3241402")
add_versions("v1.41.0", "cb89a8b9f686c5ccf7ed09a9e0ece151a73ebebc17af3813159c335b02181794")
@ -32,15 +33,20 @@ package("libuv")
elseif is_plat("linux") then
add_syslinks("pthread", "dl")
elseif is_plat("windows", "mingw") then
add_syslinks("advapi32", "iphlpapi", "psapi", "user32", "userenv", "ws2_32", "kernel32", "gdi32", "winspool", "shell32", "ole32", "oleaut32", "uuid", "comdlg32")
add_syslinks("advapi32", "iphlpapi", "psapi", "user32", "userenv", "ws2_32", "shell32", "ole32", "uuid", "dbghelp")
end
on_load("windows", function (package)
package:add("links", "uv" .. (package:config("shared") and "" or "_a"))
local version = package:version()
if version:ge("1.45") then
package:add("links", package:config("shared") and "uv" or "libuv")
else
package:add("links", package:config("shared") and "uv" or "uv_a")
end
if package:config("shared") then
package:add("defines", "USING_UV_SHARED")
end
if package:version():ge("1.40") and package:version():lt("1.44") then
if version:ge("1.40") and version:lt("1.44") then
package:add("linkdirs", path.join("lib", package:debug() and "Debug" or "Release"))
end
end)
@ -48,6 +54,7 @@ package("libuv")
on_install("windows", function (package)
local configs = {"-DLIBUV_BUILD_TESTS=OFF", "-DLIBUV_BUILD_BENCH=OFF"}
table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:debug() and "Debug" or "Release"))
table.insert(configs, "-DLIBUV_BUILD_SHARED=" .. (package:config("shared") and "ON" or "OFF"))
import("package.tools.cmake").install(package, configs)
if package:version():lt("1.40") then
os.cp("include", package:installdir())

@ -17,6 +17,7 @@ package("tbb")
add_versions("2021.4.0", "021796c7845e155e616f5ecda16daa606ebb4c6f90b996e5c08aebab7a8d3de3")
add_versions("2021.5.0", "e5b57537c741400cf6134b428fc1689a649d7d38d9bb9c1b6d64f092ea28178a")
add_versions("2021.7.0", "2cae2a80cda7d45dc7c072e4295c675fff5ad8316691f26f40539f7e7e54c0cc")
add_versions("2021.10.0", "487023a955e5a3cc6d3a0d5f89179f9b6c0ae7222613a7185b0227ba0c83700b")
else
add_urls("https://github.com/oneapi-src/oneTBB/archive/v$(version).tar.gz")
add_versions("2020.3", "ebc4f6aa47972daed1f7bf71d100ae5bf6931c2e3144cf299c8cc7d041dca2f3")
@ -25,6 +26,7 @@ package("tbb")
add_versions("2021.4.0", "021796c7845e155e616f5ecda16daa606ebb4c6f90b996e5c08aebab7a8d3de3")
add_versions("2021.5.0", "e5b57537c741400cf6134b428fc1689a649d7d38d9bb9c1b6d64f092ea28178a")
add_versions("2021.7.0", "2cae2a80cda7d45dc7c072e4295c675fff5ad8316691f26f40539f7e7e54c0cc")
add_versions("2021.10.0", "487023a955e5a3cc6d3a0d5f89179f9b6c0ae7222613a7185b0227ba0c83700b")
add_patches("2021.2.0", path.join(os.scriptdir(), "patches", "2021.2.0", "gcc11.patch"), "181511cf4878460cb48ac0531d3ce8d1c57626d698e9001a0951c728fab176fb")
add_patches("2021.5.0", path.join(os.scriptdir(), "patches", "2021.5.0", "i386.patch"), "1a1c11724839cf98b1b8f4d415c0283ec7719c330b11503c578739eb02889ec0")
@ -56,6 +58,8 @@ package("tbb")
local configs = {"-DTBB_TEST=OFF", "-DTBB_STRICT=OFF"}
table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:debug() and "Debug" or "Release"))
if package:is_plat("mingw") then
io.replace("cmake/compilers/Clang.cmake", "-Wl,-z,relro,-z,now,-z,noexecstack", "", {plain = true})
io.replace("cmake/compilers/GNU.cmake", "-Wl,-z,relro,-z,now,-z,noexecstack", "", {plain = true})
table.insert(configs, "-DCMAKE_SYSTEM_PROCESSOR=" .. (package:is_arch("x86_64") and "AMD64" or "i686"))
end
import("package.tools.cmake").install(package, configs)

Loading…
Cancel
Save