From ec4ad04c429017d68c1b0a4b30fef7592f989e84 Mon Sep 17 00:00:00 2001 From: sunrisepeak Date: Sun, 12 Jul 2026 02:39:27 +0800 Subject: [PATCH] feat(xpkg): add libxpkg 0.0.44 --- .../2026-07-12-add-libxpkg-0.0.44-plan.md | 61 +++++++++++++++++++ README.md | 2 +- pkgs/x/xpkg.lua | 21 +++++++ 3 files changed, 83 insertions(+), 1 deletion(-) create mode 100644 .agents/docs/2026-07-12-add-libxpkg-0.0.44-plan.md diff --git a/.agents/docs/2026-07-12-add-libxpkg-0.0.44-plan.md b/.agents/docs/2026-07-12-add-libxpkg-0.0.44-plan.md new file mode 100644 index 0000000..a909efd --- /dev/null +++ b/.agents/docs/2026-07-12-add-libxpkg-0.0.44-plan.md @@ -0,0 +1,61 @@ +# Add libxpkg 0.0.44 to mcpp-index + +**Date**: 2026-07-12 + +**Package**: `mcpplibs.xpkg` + +**Upstream release**: `openxlings/libxpkg` `v0.0.44` + +**Upstream commit**: `343a1fd9a697ba868af209b43862899b05a580c8` + +## Package shape + +libxpkg is an external Form-A C++23 module repository. The release contains its +own `mcpp.toml`; the index descriptor therefore remains a resource pointer and +does not duplicate upstream build metadata. Version 0.0.44 exports the existing +`mcpplibs.xpkg` module surface and adds the resource-normalization work required +by xlings. + +No feature is added: this is a version registration for an upstream module +package, not a source-gated optional component. + +## Resources and mirrors + +All three platforms use the same GitHub tag archive and SHA256: + +- GLOBAL: `https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.44.tar.gz` +- CN: `https://gitcode.com/mcpp-res/xpkg/releases/download/0.0.44/xpkg-0.0.44.tar.gz` +- SHA256: `152a27425ba418312182bddb316c8c5bc636bbd8a37faf30e75390dc844e2e95` + +The GLOBAL archive was downloaded independently twice. The CN release asset was +uploaded from those exact bytes and then downloaded publicly: HTTP 200, equal +size (127252 bytes), equal SHA256, and byte-identical by `cmp`. + +Version 0.0.43 is intentionally not registered. The ecosystem integration uses +the final 0.0.44 release, which includes the target-platform context required by +the xpkg normalization boundary. + +## Example decision + +No new workspace example is committed for this version-only update. `mcpplibs` +is mcpp's default remote index name: the resolver can see an unpublished version +through `[indices].mcpplibs.path`, but the fetch subprocess asks xlings for the +same named registry and resolves the already-published remote tree. Giving the +path index a different alias cannot find a descriptor whose declared namespace +is `mcpplibs`. This is the same default-index local-override class that keeps the +public `imgui` module outside the workspace in `validate.yml`. + +A local experiment reached this boundary after resolving the toolchain and then +failed at `fetch 'mcpplibs.xpkg@0.0.44'`; therefore it is not presented as an +end-to-end pass. Adding a git dependency would only test upstream and would not +exercise this descriptor, so it would be misleading. The existing full +workspace remains the regression gate; the new descriptor is covered directly +by strict parsing, mirror validation, and resource byte verification. + +## Verification plan + +1. Parse `pkgs/x/xpkg.lua` with Lua and CI-pinned mcpp 0.0.87. +2. Run the repository mirror lint and confirm the new CN URL is reachable. +3. Run the repository's existing `mcpp test --workspace` CI matrix to prove the + version addition does not regress current consumers. +4. Open a PR and require all validation jobs to pass before merge. diff --git a/README.md b/README.md index 8c483a4..9a9ec29 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ mcpp self config --mirror CN # 切换至国内镜像,默认使用 GLOBAL 上 | 形态 | 示例 | |------|------| -| 原生模块库(Form A) | [`mcpplibs.tinyhttps`](pkgs/t/tinyhttps.lua) · [`tensorvia-cpu`](pkgs/t/tensorvia-cpu.lua) | +| 原生模块库(Form A) | [`mcpplibs.xpkg`](pkgs/x/xpkg.lua) · [`mcpplibs.tinyhttps`](pkgs/t/tinyhttps.lua) · [`tensorvia-cpu`](pkgs/t/tensorvia-cpu.lua) | | C 源码 compat(含 `features`) | [`compat.cjson`](pkgs/c/compat.cjson.lua) · [`compat.zlib`](pkgs/c/compat.zlib.lua) | | header-only(含 `features`) | [`compat.eigen`](pkgs/c/compat.eigen.lua) | | 外部构建系统(`install()` 从源码构建) | [`compat.openblas`](pkgs/c/compat.openblas.lua)(Make) · [`compat.opencv`](pkgs/c/compat.opencv.lua)(CMake) | diff --git a/pkgs/x/xpkg.lua b/pkgs/x/xpkg.lua index 51178f1..d5df805 100644 --- a/pkgs/x/xpkg.lua +++ b/pkgs/x/xpkg.lua @@ -12,6 +12,13 @@ package = { xpm = { linux = { + ["0.0.44"] = { + url = { + GLOBAL = "https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.44.tar.gz", + CN = "https://gitcode.com/mcpp-res/xpkg/releases/download/0.0.44/xpkg-0.0.44.tar.gz", + }, + sha256 = "152a27425ba418312182bddb316c8c5bc636bbd8a37faf30e75390dc844e2e95", + }, ["0.0.42"] = { url = { GLOBAL = "https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.42.tar.gz", @@ -42,6 +49,13 @@ package = { }, }, macosx = { + ["0.0.44"] = { + url = { + GLOBAL = "https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.44.tar.gz", + CN = "https://gitcode.com/mcpp-res/xpkg/releases/download/0.0.44/xpkg-0.0.44.tar.gz", + }, + sha256 = "152a27425ba418312182bddb316c8c5bc636bbd8a37faf30e75390dc844e2e95", + }, ["0.0.42"] = { url = { GLOBAL = "https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.42.tar.gz", @@ -72,6 +86,13 @@ package = { }, }, windows = { + ["0.0.44"] = { + url = { + GLOBAL = "https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.44.tar.gz", + CN = "https://gitcode.com/mcpp-res/xpkg/releases/download/0.0.44/xpkg-0.0.44.tar.gz", + }, + sha256 = "152a27425ba418312182bddb316c8c5bc636bbd8a37faf30e75390dc844e2e95", + }, ["0.0.42"] = { url = { GLOBAL = "https://github.com/openxlings/libxpkg/archive/refs/tags/v0.0.42.tar.gz",