Skip to content

Commit 13e2da0

Browse files
2026.10.30.1: target sets and legs; the packaging model revised; tests built once and run elsewhere; run coverage; descriptor keys by the target's row; the build's contract (#862)
Co-authored-by: speak-agent <248744407+speak-agent@users.noreply.github.com>
1 parent db3b815 commit 13e2da0

106 files changed

Lines changed: 7051 additions & 1373 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.agents/docs/2026-10-29-ecosystem-target-sets-packaging-and-editors-design.md‎

Lines changed: 605 additions & 0 deletions
Large diffs are not rendered by default.

‎.agents/docs/README.md‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ superseded_by: 2026-09-07-....md # when status is superseded
1818
---
1919
```
2020

21-
341 records.
21+
342 records.
2222

2323
## By subject
2424

@@ -94,6 +94,7 @@ Records that declare one. Everything else is listed by date below.
9494
### platform
9595

9696
- [另一架构的 ok 映像的运行、测试与打包,以及 ok 映像与 Web 的关系(2026.10.29.1)](2026-10-29-openkal-run-test-pack-design.md) — active
97+
- [生态设计:目标集合与腿、打包模型 rev、运行覆盖、不回落、外部构建接入、mcppls 单包与编辑器](2026-10-29-ecosystem-target-sets-packaging-and-editors-design.md) — active
9798
- [平台 part 2:打包与分发——三维模型、通用包、单文件、okb、体积,以及 openkal 0.17.2 轮](2026-10-28-platforms-part2-packaging-and-distribution-design.md) — landed
9899
- [平台:目标体系的通用扩展;openkal 作为第一个平台包;IDE 一线与 mcppls 的同批升级](2026-10-28-platforms-design.md) — landed
99100

@@ -151,6 +152,7 @@ Records that declare one. Everything else is listed by date below.
151152
### 2026-10
152153

153154
- [另一架构的 ok 映像的运行、测试与打包,以及 ok 映像与 Web 的关系(2026.10.29.1)](2026-10-29-openkal-run-test-pack-design.md) — active
155+
- [生态设计:目标集合与腿、打包模型 rev、运行覆盖、不回落、外部构建接入、mcppls 单包与编辑器](2026-10-29-ecosystem-target-sets-packaging-and-editors-design.md) — active
154156
- [平台 part 2:打包与分发——三维模型、通用包、单文件、okb、体积,以及 openkal 0.17.2 轮](2026-10-28-platforms-part2-packaging-and-distribution-design.md) — landed
155157
- [平台:目标体系的通用扩展;openkal 作为第一个平台包;IDE 一线与 mcppls 的同批升级](2026-10-28-platforms-design.md) — landed
156158
- [生态设计 part 2:openkal 的最小原子与二进制映像、其上的 `mcpplibs.os`,以及 part 1 的收尾与回归记录](2026-10-26-ecosystem-part2-os-library-over-openkal-design.md) — active

‎.github/workflows/ci-linux-e2e.yml‎

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
name: ci-linux-e2e
22

33
# The e2e suite (tests/e2e/run_all.sh) on Linux, called by ci.yml beside
4-
# ci-linux.yml after the Linux build. Four shards, assigned by measured
5-
# duration (tests/e2e/timings/linux.tsv, rule R4 of the 2026-10-02 CI record),
4+
# ci-linux.yml after the Linux build. Six shards, assigned by measured
5+
# duration (tests/e2e/timings/linux.tsv, rule R4 of the 2026-10-02 CI record):
6+
# the table holds about 72 minutes of tests (2026-10-30, with the target-set
7+
# and packaging tests of 2026.10.30.1), about 12 a shard,
68
# each running the one binary build.yml produced (use-built-mcpp, rule R1).
79
# Each shard writes a per-test report that the e2e-coverage job of ci.yml reads
810
# (rule R5).
@@ -15,15 +17,15 @@ on:
1517

1618
jobs:
1719
e2e:
18-
name: e2e ${{ matrix.shard }}/4 (linux x86_64, self-host)
20+
name: e2e ${{ matrix.shard }}/6 (linux x86_64, self-host)
1921
runs-on: ubuntu-24.04
2022
timeout-minutes: 45
2123
strategy:
2224
fail-fast: false
2325
matrix:
24-
shard: [1, 2, 3, 4]
26+
shard: [1, 2, 3, 4, 5, 6]
2527
env:
26-
E2E_SHARD: ${{ matrix.shard }}/4
28+
E2E_SHARD: ${{ matrix.shard }}/6
2729
E2E_TIMINGS: tests/e2e/timings/linux.tsv
2830
E2E_REPORT: ${{ github.workspace }}/e2e-report-linux-${{ matrix.shard }}.tsv
2931
MCPP_HOME: /home/runner/.mcpp

‎.github/workflows/ci-target-matrix.yml‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -420,6 +420,14 @@ jobs:
420420
exit 1
421421
fi
422422
echo "ok: wasm32-emscripten ran through the payload's runner; the decoy node was never run"
423+
# #851 (e2e 981) needs the emsdk payload this step has just installed;
424+
# the shards have none and skip it, so it runs here, in that home.
425+
MCPP="$MCPP_UNDER_TEST" bash tests/e2e/981_a_web_link_has_the_profiles_level_and_the_wasm_exception_model.sh 2>&1 \
426+
| tee "$RUNNER_TEMP/981.log"
427+
if grep -q '^SKIP' "$RUNNER_TEMP/981.log" || ! grep -qx 'PASS: 981' "$RUNNER_TEMP/981.log"; then
428+
echo "::error::e2e 981 did not run to its PASS line over the installed emsdk"
429+
exit 1
430+
fi
423431
424432
coverage:
425433
# THE DENOMINATOR. Every check above is per host, and no per-host check

‎.github/workflows/cross-build-test.yml‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -431,6 +431,18 @@ jobs:
431431
grep -qxF "$line" "$log" || { echo "::error::797 did not print: $line"; exit 1; }
432432
done
433433
434+
# The Windows launcher of an ok-image tree (`bin/<name>.exe`, built over
435+
# the platform's hosted arrangement) finds its package from a Windows
436+
# path. The shards have no wine; this job does.
437+
- name: "e2e: the Windows launcher finds its package from a Windows path (988)"
438+
run: |
439+
set -o pipefail
440+
export MCPP_VENDORED_XLINGS="$XLINGS_BIN"
441+
log="$RUNNER_TEMP/988.log"
442+
bash tests/e2e/988_the_windows_launcher_finds_its_package_from_a_windows_path.sh 2>&1 | tee "$log"
443+
grep -qxF "PASS: 988 the Windows launcher finds its package from a Windows path" "$log" \
444+
|| { echo "::error::988 did not print its PASS line"; exit 1; }
445+
434446
# 257 needs a Linux-hosted MinGW compiler AND wine, which only this job
435447
# has; on the shards it skipped, and it had run on no runner (finding F9
436448
# of the 2026-10-02 CI record).

‎CHANGELOG.md‎

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,117 @@
44
> Each `## [<version>]` section is that release's notes. Entries are written in English
55
> from 2026.9.28.3 on; earlier entries remain as written.
66

7+
## [2026.10.30.1] - 2026-10-30
8+
9+
### Added
10+
11+
- **Target sets (SPEC-015).** A `--target` whose first segment is a system
12+
word names every row of the target table with that system and environment:
13+
`openkal` is `x86_64-openkal` and `aarch64-openkal`, `linux-musl` the musl
14+
rows this mcpp builds. Each member is a leg. `build` builds every leg (planned
15+
one after another, built at once); `run` runs the first leg this machine
16+
reaches, its own architecture first; `test` runs the legs it reaches, reports
17+
the others built and not run, and fails when no test ran. The `mcpp.build`
18+
envelope adds `legs`, the events their `triple`; `self env` adds `legs`
19+
(e2e 963). `[build] target` takes one target.
20+
- **Tests built once, run elsewhere.** `mcpp test --no-run --archive <file>`
21+
writes every leg's tests with `mcpp-tests.json`; `mcpp test --archive <file>`
22+
in a checkout runs what this machine reaches and builds nothing. The archive
23+
is a tar compressed as its name states (`.tar.gz`, `.tgz`, `.tar.zst`,
24+
`.tar.xz`, `.tar`); another name is refused before the build (e2e 964). A
25+
leg of the host's own system runs from an archive as an openkal leg does
26+
(e2e 989, on every system); on macOS the first build of this release started
27+
none of them, giving each an environment entry of an empty name.
28+
- **The build's contract, `${mcpp.contract}`.** Every configuration writes
29+
`mcpp-contract.json` beside its compile database: the compiler of each
30+
language with the words every unit is compiled with (target, sysroot,
31+
target-side headers, platform and profile flags), and the link driver, its
32+
words and the archiver. A build program's action names it with
33+
`${mcpp.contract}` and reads it while ninja runs, so a foreign build system
34+
compiles for the target as the engine does; the engine's own C++ dialect and
35+
module words are not in it (e2e 982). mcpp-plugins 0.21.0's `deps-cmake`
36+
compiles a cross build's subproject from it.
37+
- **`[platform] runner.hosts`, carrier entries and `descriptor_keys`.** A
38+
platform states the `<os>-<arch>` pairs its runner exists for, any number of
39+
carrier entries each for the pairs in its `hosts` (an entry of a carrier
40+
model this mcpp does not build is skipped with a warning), and the
41+
descriptor blocks its targets read (SPEC-013 §1.1, §10, §11, §14).
42+
- **`runs_on` in `mcpp-package.json`.** Where a package runs is computed once
43+
when it is packed: `self`, the pairs it runs on with what it carries, and
44+
`with.<runner>`, the pairs it runs on given the machine's runner.
45+
46+
### Changed
47+
48+
- **A pack holds the legs it names (SPEC-014 2.0).** `--target
49+
x86_64-openkal` packs that architecture; `--target openkal` packs both into
50+
one tree. The platform no longer widens a pack: `[platform] universal`,
51+
`[pack] universal` and `--no-universal` lose their effect, with a message
52+
that names the new spelling (`[pack] targets = ["openkal"]`; docs/51).
53+
Images of a platform with a runner have one layout whatever the number of
54+
legs: `bin/<name>`, `bin/<name>.exe`, `lib/<arch>/`, and with
55+
`--mode self-contained` `libexec/<runner>/<os>-<arch>/`. The image embedded
56+
in a carrier belongs to `--pkg-format single-file` only. A set of native
57+
programs is a package per leg (e2e 955, 983, 984).
58+
- **The Windows launcher is a program.** `bin/<name>.exe` replaces
59+
`bin/<name>.cmd`: no "Terminate batch job" prompt, and the process is named
60+
after the package. The POSIX launcher hands over to it under Git Bash, MSYS
61+
and Cygwin.
62+
- **`--systems` takes `<os>`, `<os>-<arch>` and `all`, and `[pack] systems`.**
63+
`--pkg-format` takes a list of containers of one staged tree (`tar,okb`),
64+
built once (e2e 985). Single files cover legs × systems (e2e 986).
65+
- **The pack summary names where the package runs.** `Runs on` and one `Not
66+
covered` line per pair the package does not reach; `mcpp.pack` adds
67+
`pkgFormats` and `runsOn`. A tree that runs nowhere is refused.
68+
- **A target reads the descriptor blocks its row names, never the build
69+
machine's (#851).** A target that is not Linux, macOS or Windows read the
70+
block of the system mcpp ran on, so a Web build took a dependency's `linux`
71+
block on Linux and its `windows` block on Windows, and an ok image the block
72+
of whichever system built it. Each row now names its blocks in order:
73+
`wasm32-emscripten` reads `emscripten`, then `linux`; `<arch>-openkal`
74+
`openkal`, then `linux` (a platform may state its own); iOS `ios`, then
75+
`macosx`; bare metal `none`. Version resolution, the synthesised manifest
76+
and the index refresh read the same block (unit `DescriptorKeys`).
77+
- **The Web link carries the profile's optimisation level (#851).** emcc runs
78+
wasm-opt and minifies the JavaScript launcher at the link, which had no
79+
`-O`: a release Web program was linked at `-O0`. The hello world's
80+
JavaScript is 13 KB rather than 66 KB (e2e 981).
81+
- **`[target.<sel>.abi] exceptions` takes the model (#851).** `"wasm"` selects
82+
WebAssembly's exception handling (`-fwasm-exceptions`), `"js"` the
83+
JavaScript model; `true` keeps the JavaScript model it has selected since
84+
2026.9.12.3. The model is part of every cache key (e2e 981).
85+
- **`mcpp emit xpkg` names where a package runs (#860).** A
86+
self-contained universal package's entry named every system with every
87+
image architecture, so an Intel Mac installed a package that carries no
88+
runner for it. Each system's block names the architectures `runs_on` gives:
89+
the carried runners for a self-contained package, the pairs the platform's
90+
runner exists for otherwise.
91+
92+
### Fixed
93+
94+
- **A name two dependencies answer to is no package's (#852).** Two
95+
dependencies whose manifests both say `rules` warned on every build, and the
96+
bare name went to one of them. It is now published for neither:
97+
`MCPP_DEP_AMBIGUOUS_RULES` lists the qualified names, each qualified name
98+
keeps its own directory, and `dep_dir("rules")` ends the build program naming
99+
both (e2e 980).
100+
- **Programs start in the Android app sandbox again (#857).** Under `run-as`
101+
(SELinux `runas_app`) every program mcpp started failed with "not found"
102+
since 2026.10.26.2. A static strace showed one failing call, before any
103+
process was created: the root directory opened for reading, which the
104+
domain may search but not read. openkal-linux 0.18.3 opens every directory
105+
handle with `O_PATH`; mcpp is built on mcpplibs.os 0.2.3, which pins it, and
106+
openkal-platform 0.18.0 carries it to every ok image and hosted program.
107+
- **A gzip stream over 4 GiB.** zlib counts in 32 bits, and mcpp handed it the
108+
whole tree at once: a `.tar.gz` of more than 4 GiB was refused as "an input
109+
over 4 GiB", by `mcpp pack` and by a test archive alike. Input and output
110+
now pass in pieces of 1 GiB, so such a tree is one gzip member as any other.
111+
- **A program that cannot be started is reported with the system's account.**
112+
Every condition beyond not found, permission and not a program was reported
113+
as "error 5" (EIO), the system's own message dropped. The classification now
114+
covers invalid, no memory, directory, not supported and too large, and the
115+
report of `mcpp test` and `mcpp test --archive` carries what was being done
116+
and the kernel layer's value.
117+
7118
## [2026.10.29.1] - 2026-10-29
8119

9120
### Fixed

‎docs/04-mcpp-toml.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1496,7 +1496,7 @@ the platform's own key names ([35 — Platforms](35-platforms.md)):
14961496

14971497
```toml
14981498
[target.'cfg(os = "openkal")']
1499-
platform = "openkal-platform@0.17.3" # or { path = "…" }, or "none"
1499+
platform = "openkal-platform@0.18.0" # or { path = "…" }, or "none"
15001500

15011501
[target.'cfg(platform = "openkal")'.layers]
15021502
c-abi = { path = "../openkal-musl" }

‎docs/08-testing.md‎

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,26 @@ otherwise, so it needs no `libc++_shared.so` on the device.
197197
The runner itself, named runners, and what a board declares are
198198
[41 — Reaching a Device](41-devices.md).
199199

200+
### Built once, run elsewhere (mcpp 2026.10.30.1+)
201+
202+
An ok image is the same bytes on every system, and a test built for
203+
`x86_64-windows-gnu` on Linux runs on Windows. `--archive` separates the two
204+
halves:
205+
206+
```bash
207+
mcpp test --target openkal --no-run --archive tests.tar.gz # build every leg's tests, write them
208+
mcpp test --archive tests.tar.gz # in a checkout: run what this machine reaches
209+
```
210+
211+
The archive holds each leg's test programs and `mcpp-tests.json`, which names
212+
each test's leg, arguments and working directory. Reading it builds nothing;
213+
the tests run in the checkout, through this machine's runner or system, and the
214+
report is `mcpp test`'s. A failed test exits 1, and so does an archive of which
215+
no test ran. Legs this machine does not reach are reported as not run
216+
([SPEC-015 §4](specs/target-sets.md)). The archive is a tar compressed as its
217+
name states: `.tar.gz` (or `.tgz`), `.tar.zst`, `.tar.xz` or `.tar`; another
218+
name is refused before anything is built.
219+
200220
## Tests that cannot run beside each other
201221

202222
`mcpp test` runs test programs on a worker pool. One board on one probe, one

0 commit comments

Comments
 (0)