Description
PR #5891 (commit 2616f7b, closes #5873) migrated the CI lint-warning gate from RUSTFLAGS="-D warnings" to Cargo's native build.warnings = "deny", committed repo-wide via .cargo/config.toml. Because .cargo/config.toml applies to every cargo invocation (CI and local alike) unless explicitly overridden per-invocation, this now also denies linker-level warnings surfaced via #[warn(linker_messages)], not just rustc/clippy/rustdoc lints.
On macOS/arm64 (Darwin 25.5.0, macOS 26.5.1), a completely plain cargo build --features full (and by extension cargo run --features full, the documented live-testing entry point in .claude/rules/continuous-improvement.md) now unconditionally fails, because Apple's ld linker emits an __eh_frame section too large warning. This is a linker artifact of the zeph binary's size on macOS's compact-unwind-table format — not a code defect, not fixable by editing source, and not caused by any individual commit's changes. It reproduced deterministically across two consecutive builds.
Sibling issue #5894 (filed CI-1280, same root cause) documents a narrower symptom: the rustdoc pre-commit gate command failing on 37 pre-existing rustdoc warnings. This finding is distinct and more severe: it blocks the single most basic operation in the project — cargo build/cargo run with no special flags — on a real developer/CI-tester platform, with no documented workaround. CI itself is unaffected (Linux runners don't hit this linker warning), and only the coverage/rustdoc CI jobs carry a CARGO_BUILD_WARNINGS=allow override — the build/test/clippy jobs do not, so this class of platform-specific linker warning is currently invisible to CI entirely (no macOS runner in the matrix).
The workaround CARGO_BUILD_WARNINGS=allow cargo build ... (mirroring CI's own override pattern) unblocks the build but is undocumented for local/live-testing use.
Reproduction Steps
- On
main (HEAD 2616f7b or later, .cargo/config.toml present) on macOS/arm64, run:
cargo build --features full
- Observe the build fail (reproduced twice consecutively):
warning: linker stderr: ld: __eh_frame section too large (max 16MB) to encode dwarf unwind offsets in compact unwind table, performance of exception handling might be affected
|
= note: `#[warn(linker_messages)]` on by default
error: `zeph` (bin "zeph") generated 1 warning
error: warnings are denied by `build.warnings` configuration
- Confirm the workaround unblocks it:
CARGO_BUILD_WARNINGS=allow cargo build --features full succeeds.
Expected Behavior
A plain cargo build/cargo run should succeed without an undocumented environment variable override, on any platform CI or contributors actually use — either by scoping build.warnings = "deny" to CI invocations only (mirroring how coverage/rustdoc jobs already opt OUT), by using category-level granularity if Cargo 1.97 supports it (linker warnings allowed, rustc/clippy/rustdoc still denied), or by eliminating the eh_frame overflow itself (e.g. split-debuginfo / unwind-table strategy tuning).
Actual Behavior
cargo build --features full and cargo run --features full fail unconditionally on macOS/arm64 with error: warnings are denied by build.warnings configuration, blocking all local development and live testing on this platform until a developer independently discovers CARGO_BUILD_WARNINGS=allow.
Environment
Related
Spec
.local/specs/051-cargo-build-warnings-linker-eh-frame/spec.md
Description
PR #5891 (commit 2616f7b, closes #5873) migrated the CI lint-warning gate from
RUSTFLAGS="-D warnings"to Cargo's nativebuild.warnings = "deny", committed repo-wide via.cargo/config.toml. Because.cargo/config.tomlapplies to everycargoinvocation (CI and local alike) unless explicitly overridden per-invocation, this now also denies linker-level warnings surfaced via#[warn(linker_messages)], not just rustc/clippy/rustdoc lints.On macOS/arm64 (Darwin 25.5.0, macOS 26.5.1), a completely plain
cargo build --features full(and by extensioncargo run --features full, the documented live-testing entry point in.claude/rules/continuous-improvement.md) now unconditionally fails, because Apple'sldlinker emits an__eh_frame section too largewarning. This is a linker artifact of thezephbinary's size on macOS's compact-unwind-table format — not a code defect, not fixable by editing source, and not caused by any individual commit's changes. It reproduced deterministically across two consecutive builds.Sibling issue #5894 (filed CI-1280, same root cause) documents a narrower symptom: the rustdoc pre-commit gate command failing on 37 pre-existing rustdoc warnings. This finding is distinct and more severe: it blocks the single most basic operation in the project —
cargo build/cargo runwith no special flags — on a real developer/CI-tester platform, with no documented workaround. CI itself is unaffected (Linux runners don't hit this linker warning), and only thecoverage/rustdocCI jobs carry aCARGO_BUILD_WARNINGS=allowoverride — thebuild/test/clippyjobs do not, so this class of platform-specific linker warning is currently invisible to CI entirely (no macOS runner in the matrix).The workaround
CARGO_BUILD_WARNINGS=allow cargo build ...(mirroring CI's own override pattern) unblocks the build but is undocumented for local/live-testing use.Reproduction Steps
main(HEAD 2616f7b or later,.cargo/config.tomlpresent) on macOS/arm64, run:CARGO_BUILD_WARNINGS=allow cargo build --features fullsucceeds.Expected Behavior
A plain
cargo build/cargo runshould succeed without an undocumented environment variable override, on any platform CI or contributors actually use — either by scopingbuild.warnings = "deny"to CI invocations only (mirroring howcoverage/rustdocjobs already opt OUT), by using category-level granularity if Cargo 1.97 supports it (linker warnings allowed, rustc/clippy/rustdoc still denied), or by eliminating the eh_frame overflow itself (e.g. split-debuginfo / unwind-table strategy tuning).Actual Behavior
cargo build --features fullandcargo run --features fullfail unconditionally on macOS/arm64 witherror: warnings are denied by build.warnings configuration, blocking all local development and live testing on this platform until a developer independently discoversCARGO_BUILD_WARNINGS=allow.Environment
fullRelated
.cargo/config.tomlbuild.warnings=deny), narrower rustdoc-gate symptom.cargo/config.tomlSpec
.local/specs/051-cargo-build-warnings-linker-eh-frame/spec.md