Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto-update glaze to v3.3.2 #5149

Merged
merged 4 commits into from
Sep 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 10 additions & 7 deletions packages/g/glaze/xmake.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ package("glaze")
add_urls("https://github.com/stephenberry/glaze/archive/refs/tags/$(version).tar.gz",
"https://github.com/stephenberry/glaze.git")

add_versions("v3.3.2", "e492d3f662c3c096ce7abac86780af6c84f74c4f19b29223ad92fccc054aafad")
add_versions("v3.1.7", "388483bb3dfa1fe25c1dfec24f0afd1651e0303833cfa1b7f51020a2569e992a")
add_versions("v2.9.5", "67fda0fb0cc701451c261bb1e0c94d63bafaaba13390527521e02a034eff085e")
add_versions("v2.7.0", "8e3ee2ba725137cd4f61bc9ceb74e2225dc22b970da1c5a43d2a6833115adbfc")
Expand All @@ -21,15 +22,16 @@ package("glaze")
add_deps("cmake")

if on_check then
on_check("windows", function (package)
if package:is_plat("windows") then
local vs = package:toolchain("msvc"):config("vs")
assert(vs and tonumber(vs) >= 2022, "package(glaze): need vs >= 2022")
end
on_check(function (package)
assert(package:check_cxxsnippets({test = [[
constexpr void f() {
static constexpr int g = 1;
}
]]}, {configs = {languages = "c++2b"}}), "package(glaze) Require at least C++23.")
end)
end

on_install("windows", "linux", "bsd", "mingw", "wasm", function (package)
on_install("windows", "linux", "macosx", "bsd", "mingw", "wasm", function (package)
local version = package:version()
if version and version:ge("2.9.5") then
if package:has_tool("cxx", "cl", "clang_cl") then
Expand All @@ -38,6 +40,7 @@ package("glaze")

import("package.tools.cmake").install(package, {
"-Dglaze_DEVELOPER_MODE=OFF",
"-DCMAKE_CXX_STANDARD=23",
"-DCMAKE_BUILD_TYPE=" .. (package:is_debug() and "Debug" or "Release")
})
else
Expand All @@ -62,5 +65,5 @@ package("glaze")
obj_t obj{};
glz::write_json(obj, buffer);
}
]]}, {configs = {languages = "c++20"}}))
]]}, {configs = {languages = "c++2b"}}))
end)
Loading