Skip to content

[temp][do not merge] probe: Windows SDK outside C:, Termux first run, cl.exe module roles - #791

Closed
Sunrisepeak wants to merge 9 commits into
mainfrom
probe/windows-sdk-termux-msvc-roles
Closed

Sunrisepeak wants to merge 9 commits into
mainfrom
probe/windows-sdk-termux-msvc-roles

Conversation

@Sunrisepeak

Copy link
Copy Markdown
Member

Temporary probe for .agents/docs/2026-10-10-one-source-one-meaning-design.md (O5, O6, O7, O8). Every other workflow is removed on this branch; the scripts print what they observe and assert nothing. Do not merge.

  • windows-sdk: the published mcpp 2026.10.8.1 with the Windows SDK moved out of C:\Program Files (x86)\Windows Kits\10 and the registry updated, as on a machine whose SDK was installed to another drive: nothing configured / [toolchain] windows = "llvm@23.1.3" / --toolchain llvm@23.1.3.
  • msvc-module-roles: which cl.exe options compile each module role in .cpp, .cppm and .ixx, and which write a BMI.
  • termux-docker: first run of the published aarch64 mcpp in a Termux userland on a native arm64 runner, with plan stage timings.
  • termux-emulator: the Android app sandbox (SELinux) through the debuggable Termux APK and run-as on an API 34 x86_64 emulator: hard links, first run.

Sunrisepeak added a commit that referenced this pull request Oct 10, 2026
…r action output, module roles from declarations, Termux (#792)

Release 2026.10.10.1. Design: `.agents/docs/2026-10-10-one-source-one-meaning-design.md` (revision 6).

## Workspace: the prefix carries the meaning (#785, #786)
- `[workspace.toolchain]`, `[workspace.indices]`, `[workspace.profile.<name>]`, `[workspace.target.<selector>]` (with `.build`, `.abi`, `.runtime`, `.xlings.workspace`) and `[workspace.xlings]` mirror the tables of the same name and are read by the same reader (`parse_document` over the document under `workspace.`). A table without the prefix describes its own package.
- Merge rule by key (W3): declared scalars stay the member's, lists put the workspace first, named tables merge key by key, conditional rows are inherited ahead of the member's. Package-only keys and unknown `[workspace]` tables are refused.
- The root's own tables still reach members by position, unchanged, in `mcpp.pm.compat.workspace_position`, with a `manifest/workspace-position` warning naming the canonical spelling (removed in 1.0.0). W7 warns about package tables on a root without `[package]` (`--strict`: error). A note asks for the `mcpp` floor when the layer is used.
- Members are grouped by their configuration as it evaluates for the target; the virtual root carries a member's conditional `dialect_cxxflags`/`.abi` rows (R1b: `DIAL=0` → `DIAL=2`).
- `mcpp.manifest.key_registry`: the class of each key; the parser's `[build]` and conditional-build known keys, the shared conditional keys and W7's package tables are derived from it.
- `mcpp publish` writes the layer into the member's own tables (W6).

## Action outputs have one writer (#778)
- Prepare writes no placeholder; a generated unit enters the plan from its action's declaration. A generated module interface without `.provides()` is `degraded`.
- `mcpp::out_dir()` is per configuration and package (`target/.build-mcpp/out/<configuration>/<package>`), recorded as `outDir` in `resolution.json`.

## Module role from the declaration (#790)
- A C++ unit that provides a module takes the module rule whatever its extension; cl.exe implementation partitions get `/internalPartition` (measured in probe #791).

## Toolchains, Windows, Android
- `--toolchain` replacing a declared toolchain warns (D11).
- Windows SDK from `KitsRoot10` and `%ProgramFiles%`; `vswhere` from `%ProgramFiles(x86)%`; the MSVC probe names the missing half for the first-run notice and for the refusal of a specified toolchain (D15–D18).
- Android host recognised (`self env` → `android`), same default toolchain (D21); argv shell resolved (D28); the managed toolchain's library path no longer reaches ninja's environment (D29); install hints by failure class and xlings extract/hook progress shown (D22, D23).
- xlings pinned to 2026.10.10.2 (openxlings/xlings#651: hard-link fallback, error classes, progress); bootstrap mcpp 2026.10.8.1.
- Termux fresh-install jobs (termux-docker aarch64, Android 14 emulator app sandbox) in `ci-fresh-install.yml`.

## Late fixes from CI
- A workspace member's build program keeps its out dir beside its cache, so `emit build-database` reuses the build's run (e2e 839 B4).
- `mcpp index list` reads the same effective indices as resolution (e2e 44).
- A failed install names the first address's failure ahead of the `compat` retries.
- Tests read a tool binding from `build.ninja` as a command line (`env LD_LIBRARY_PATH=...` prefix, D29); the graphics checks read `outDir` (`.github/tools/out_dir.sh`).
- The Linux and macOS e2e jobs install the `mcpplibs.cmdline` payloads e2e 32/33/40 link, which a warm cache used to hold.

## Tests
- e2e 893–901, each failing on 2026.10.8.1: workspace layer, compat reading, conditional rows, one writer, per-configuration out_dir, module units in `.cpp` (llvm and gcc), `--toolchain` note, publish write-back, the tools' library path.
- Unit: `test_key_registry` (registry vs `kWorkspaceBuildKeys` and the grouping key, layer parsing and refusals, W7, W3 merges, grouping), `MsvcProbe` description.
- e2e 12, 44, 210 moved to `[workspace.indices]`; 120 and 773 keep the position reading as its coverage; 111 reads the new output place.

## Ecosystem
- openxlings/xlings#651 (released 2026.10.10.2), openxlings/xim-pkgindex#947 (glibc 2.44.3 r4, payload hard-link check), mcpp-community/mcpp-plugins#45 (tests read `outDir`).

Closes #785, closes #786, closes #778, closes #790.
@Sunrisepeak

Copy link
Copy Markdown
Member Author

Probe finished. Its measurements are in the design record (.agents/docs/2026-10-10-one-source-one-meaning-design.md: cl.exe implementation partitions take /internalPartition, the Windows SDK outside C:, the Termux first run). Released in 2026.10.10.1 and 2026.10.10.2; the Termux jobs now run in ci-fresh-install.yml.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant