Add regression test for sysroot flags on assembly actions
@nradakovic ci sta già lavorando.
Dal 15/9/2026.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Context
Issue #141 fixed missing --sysroot for assemble/preprocess-assemble actions (fix: sysroot_link_flags feature). The fix shipped without regression coverage because a naive test is unsound.
Why a naive test doesn't work
A .S fixture including a sysroot header (e.g. <features.h>) passes even without --sysroot: the host's /usr/include provides the same glibc (2.39) headers as the autosd10 sysroot, so header resolution alone cannot distinguish sysroot from host fallback — the exact failure mode of #141.
Proposed approach
Assert the resolved command line instead of build success:
- A guardrail-style analysis test (pattern:
tests/guardrails/legacy_feature_guard.bzl)
that resolves the active toolchain and verifies--sysroot=<sysroot>is
present in the flags forassembleandpreprocess-assembleactions, and
that-Wl,--sysrootis NOT (linker-only flag). - Alternative: an
aquery-based check on a.Starget'sCppCompileaction.
Acceptance criteria
- Test fails when
assembly_actionsis removed from thesysroot_link_flagsfeature. - Test fails if
-Wl,--sysrootleaks into assembly actions. - Runs on Linux x86_64 and aarch64 configs; no target hardware needed.
- Lingua principale
- Starlark
- Stelle
- 2
- Fork
- 11
- Merge medio
- 1g 17h
- PR unite (30g)
- 11
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di eclipse-score/bazel_cpp_toolchains
-
action config documentation feature improvements p3 template
eclipse-score/bazel_cpp_toolchains#138 · 1 commento · 1 assegnatario ·
-
eclipse-score/bazel_cpp_toolchains#129 · 1 assegnatario ·
-
blocked bug p2 toolchain pkg
eclipse-score/bazel_cpp_toolchains#68 · 27 commenti · 1 assegnatario ·
-
bug feature p3 template wip
eclipse-score/bazel_cpp_toolchains#53 · 1 assegnatario ·