From 66095e55985777dd84be140b328f0ee97af19ae9 Mon Sep 17 00:00:00 2001 From: Salman Mohammed Date: Mon, 9 Nov 2026 15:38:41 -0500 Subject: [PATCH] fix: inline ARM64 atomics in Sprig image build (#9291) ## Summary Sprig's ARM64 container fails to link because bundled D-Bus emits a call to GCC's `__aarch64_ldadd4_sync` helper, which Rust's static musl link does not supply. AMD64 succeeds, but the failed ARM64 job blocks publication of the multi-architecture image. Set the ARM64 musl C compiler flags to `-mno-outline-atomics` in the image builder. This emits baseline ARM64 atomic instructions inline instead of requiring the missing helper. Other targets and the runtime image configuration are unchanged. ### Related issue No duplicate fix found. [Failing build](https://github.com/block/buzz/actions/runs/42667527024/job/129335071943). The [previous main build](https://github.com/block/buzz/actions/runs/42642040718) has the same failure, before the MCP dependency update. ### Testing The exact local ARM64 image build passed: `docker build --platform linux/arm64 --file Dockerfile.sprig --tag buzz-sprig:arm64-link-fix .`. The resulting `sprig --version` command passed. The `buzz-agent` personality reached its expected missing-provider configuration error. Broad local checks were not run. Generated with Codex Signed-off-by: Salman Mohammed --- Dockerfile.sprig | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile.sprig b/Dockerfile.sprig index a2867f53d0..a8ca3b7bce 100644 --- a/Dockerfile.sprig +++ b/Dockerfile.sprig @@ -16,6 +16,10 @@ RUN apk add --no-cache \ protoc WORKDIR /build COPY . . +# GCC's outlined ARM64 atomics require libgcc helpers that Rust's static musl +# link does not provide (notably __aarch64_ldadd4_sync in vendored D-Bus). +# Emit baseline ARM64 atomics inline; cc-rs applies this only to that target. +ENV CFLAGS_aarch64_unknown_linux_musl="-mno-outline-atomics" RUN cargo build --locked --profile sprig -p sprig \ && strip target/sprig/sprig