Skip to content

Commit fd8220a

Browse files
committed
ci: 引导用的 mcpp 自带一份 xlings,而那份早于一次索引移动
一个 mcpp 发布**内嵌**一份 xlings 在 `<install>/registry/bin/xlings`,而解析 runtime binding 的是**那一份**,不是 quick_install 装的那一份。`xim:glibc` 的 latest 移到 2.44.2,而只有 xlings 2026.8.27.1 改为从索引读默认绑定 (openxlings/xlings#567)。旧的内嵌副本要 `glibc@2.44`,干净环境装出 `2.44.2`, 工具链 post-install 停住: error: selected RuntimeBinding glibc@2.44 requires payload '.../xpkgs/xim-x-glibc/2.44', but it is not installed 在每一台**新**机器上出现,在任何已存在的机器上都不出现 —— 所以它在开发机上不可见。 索引的 pkgs/g/glibc.lua 把这次失败逐字记着。 ⭐ mcpp 2026.8.27.1(mcpp-community/mcpp#515)内嵌的就是 2026.8.27.1,那之后本步骤 是空操作。只在版本不同时替换,并**打印替换了什么** —— 静默替换不可能发生。 待 pin 发布后移除。
1 parent 435b578 commit fd8220a

1 file changed

Lines changed: 68 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,40 @@ jobs:
8080
done
8181
mcpp --version
8282
mcpp self config --mirror GLOBAL
83+
# ⚠️⚠️ TRANSITION: THE BOOTSTRAP mcpp CARRIES ITS OWN xlings, AND
84+
# THAT COPY PREDATES AN INDEX MOVE.
85+
#
86+
# An mcpp release BUNDLES an xlings at `<install>/registry/bin/xlings`
87+
# (mcpp's `pinned::kXlingsVersion`), and that copy — not the one
88+
# installed above — is what resolves runtime bindings for everything
89+
# mcpp does. `xim:glibc`'s `latest` moved to 2.44.2, and only
90+
# xlings 2026.8.27.1 reads the default binding from the index instead
91+
# of a constant compiled into itself (openxlings/xlings#567). An
92+
# older bundled copy asks for `glibc@2.44`, a clean environment
93+
# installs `2.44.2`, and the toolchain post-install fixup stops:
94+
#
95+
# error: selected RuntimeBinding glibc@2.44 requires payload
96+
# '…/xpkgs/xim-x-glibc/2.44', but it is not installed
97+
#
98+
# on every NEW environment and on none that already existed. The
99+
# index records this failure verbatim in `pkgs/g/glibc.lua`.
100+
#
101+
# ⭐ REMOVE THIS ONCE THE PIN SHIPS. mcpp 2026.8.27.1 bundles
102+
# 2026.8.27.1, so a bootstrap from it needs nothing here. The step is
103+
# a no-op when the bundled copy is already new enough, and it says
104+
# which copy it replaced so a silent substitution is not possible.
105+
mcpp_home="${MCPP_HOME:-$HOME/.mcpp}"
106+
bundled="$mcpp_home/registry/bin/xlings"
107+
if [ -x "$bundled" ] && [ -n "$(command -v xlings)" ]; then
108+
have="$("$bundled" --version 2>/dev/null | head -1)"
109+
outer="$(xlings --version 2>/dev/null | head -1)"
110+
if [ "$have" != "$outer" ]; then
111+
cp "$(command -v xlings)" "$bundled"
112+
echo "bundled xlings: $have -> $("$bundled" --version | head -1) (was older than the installed one)"
113+
else
114+
echo "bundled xlings: $have (already the installed one)"
115+
fi
116+
fi
83117
# ⭐⭐ CROSS-VALIDATION: BUILD THE mcpp UNDER REVIEW AND USE THAT ONE.
84118
#
85119
# Empty in the ordinary run, so this job keeps testing the RELEASED
@@ -309,6 +343,40 @@ jobs:
309343
done
310344
mcpp --version
311345
mcpp self config --mirror GLOBAL
346+
# ⚠️⚠️ TRANSITION: THE BOOTSTRAP mcpp CARRIES ITS OWN xlings, AND
347+
# THAT COPY PREDATES AN INDEX MOVE.
348+
#
349+
# An mcpp release BUNDLES an xlings at `<install>/registry/bin/xlings`
350+
# (mcpp's `pinned::kXlingsVersion`), and that copy — not the one
351+
# installed above — is what resolves runtime bindings for everything
352+
# mcpp does. `xim:glibc`'s `latest` moved to 2.44.2, and only
353+
# xlings 2026.8.27.1 reads the default binding from the index instead
354+
# of a constant compiled into itself (openxlings/xlings#567). An
355+
# older bundled copy asks for `glibc@2.44`, a clean environment
356+
# installs `2.44.2`, and the toolchain post-install fixup stops:
357+
#
358+
# error: selected RuntimeBinding glibc@2.44 requires payload
359+
# '…/xpkgs/xim-x-glibc/2.44', but it is not installed
360+
#
361+
# on every NEW environment and on none that already existed. The
362+
# index records this failure verbatim in `pkgs/g/glibc.lua`.
363+
#
364+
# ⭐ REMOVE THIS ONCE THE PIN SHIPS. mcpp 2026.8.27.1 bundles
365+
# 2026.8.27.1, so a bootstrap from it needs nothing here. The step is
366+
# a no-op when the bundled copy is already new enough, and it says
367+
# which copy it replaced so a silent substitution is not possible.
368+
mcpp_home="${MCPP_HOME:-$HOME/.mcpp}"
369+
bundled="$mcpp_home/registry/bin/xlings"
370+
if [ -x "$bundled" ] && [ -n "$(command -v xlings)" ]; then
371+
have="$("$bundled" --version 2>/dev/null | head -1)"
372+
outer="$(xlings --version 2>/dev/null | head -1)"
373+
if [ "$have" != "$outer" ]; then
374+
cp "$(command -v xlings)" "$bundled"
375+
echo "bundled xlings: $have -> $("$bundled" --version | head -1) (was older than the installed one)"
376+
else
377+
echo "bundled xlings: $have (already the installed one)"
378+
fi
379+
fi
312380
# ⭐⭐ CROSS-VALIDATION: BUILD THE mcpp UNDER REVIEW AND USE THAT ONE.
313381
#
314382
# Empty in the ordinary run, so this job keeps testing the RELEASED

0 commit comments

Comments
 (0)