Skip to content

Stop asserting a mechanism for the ring-only rule - #4

Merged
jetm merged 1 commit into
mainfrom
provider-rationale
Sep 15, 2026
Merged

jetm merged 1 commit into
mainfrom
provider-rationale

Conversation

@jetm

@jetm jetm commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

Problem

check-provider.sh justified forbidding aws-lc-rs by the libc the agent
cross-compiles against - "the musl SDK, which clears only the ring stack". No build
has ever targeted that libc. Every triple built is a glibc one, and no published feed
carries a musl or 32-bit ARM target to build against.

The obvious replacement is also false. Building this crate for
x86_64-avocado-linux-gnu without the cross toolchain on PATH fails inside ring's
own build script:

warning: ring@0.17.14: ToolNotFound: failed to find tool "x86_64-avocado-linux-gcc"
error: failed to run custom build command for `ring v0.17.14`

So ring carries C and assembly and needs a cross C compiler like any other crate.
"ring is pure Rust, aws-lc-rs is not" does not distinguish them.

Solution

Record the rule as inherited convention from avocado-conn, name both refuted
explanations so neither gets rediscovered and written back in, and name the
measurement that would actually settle it: build the crate for each target with
aws-lc-rs substituted for ring and record which targets fail and how.

A wrong reason is worse than none here. The next person to widen the target set
checks whether the stated condition still holds, finds it never applied, and
reasonably concludes the rule is stale - which is how a real constraint gets dropped.

Reviewer notes

  • Comment only. Both cargo tree queries and the three-way exit contract are
    untouched, so a tree that passed before passes now. shellcheck clean.
  • The comment explicitly asks that no third mechanism be written in without the
    measurement, because this is the second wrong one.
  • This does not argue for relaxing the constraint. It holds in practice and
    avocado-conn enforces the same rule; only its stated justification changes.

The guard justified forbidding aws-lc-rs by the libc the agent
cross-compiles against. No build has ever targeted that libc: every
triple built is a glibc one, and no published feed carries a musl or
32-bit ARM target to build against.

The obvious replacement is also false, which is why this records what was
measured rather than a better-sounding reason. Building this crate for
x86_64-avocado-linux-gnu without the cross toolchain on PATH fails inside
ring's own build.rs with ToolNotFound for x86_64-avocado-linux-gcc, so
ring carries C and assembly and needs a cross C compiler like any other.
"ring is pure Rust, aws-lc-rs is not" does not distinguish them.

A wrong reason is worse than none on a constraint like this. The next
person to widen the target set checks whether the stated condition still
holds, finds it never applied, and reasonably concludes the rule is
stale - which is how a real constraint gets dropped. Recording the rule
as inherited convention, naming both refuted explanations and the
measurement that would settle it, leaves that reader with something they
can act on instead.

Only the comment changes. Both cargo tree queries and the three-way exit
contract are untouched, so a tree that passed before passes now.

Signed-off-by: Javier Tia <javier@peridio.com>
@jetm
jetm requested a review from nicksinas September 15, 2026 21:45
@jetm
jetm merged commit 6e883f0 into main Sep 15, 2026
1 check failed
@jetm
jetm deleted the provider-rationale branch November 19, 2026 23:58
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.

2 participants