Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 27 additions & 1 deletion .github/workflows/binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,18 @@ jobs:
os: ubuntu-latest
- target: aarch64-unknown-linux-musl
os: ubuntu-24.04-arm
# Cross-compiled from Apple silicon rather than built on macos-13.
# Xcode's toolchain and SDK are universal, so an arm64 Mac produces
# an x86-64 binary with nothing but `rustup target add` — there is
# no sysroot to fetch and no linker to configure.
#
# The Intel runners are being wound down and it shows: on the v0.6.2
# release this leg sat queued for forty-five minutes while every
# other target finished inside ninety seconds. A target nobody can
# schedule is a target that silently stops shipping, which is worse
# than one that is cross-built.
- target: x86_64-apple-darwin
os: macos-13
os: macos-latest
- target: aarch64-apple-darwin
os: macos-latest
- target: x86_64-pc-windows-msvc
Expand Down Expand Up @@ -152,6 +162,22 @@ jobs:
cp "$archive" "$alias"
sums "$alias" > "${alias}.sha256"

# A cross-built binary that is quietly the host's architecture would
# pass every other check here and fail on the first machine that
# downloaded it. Ask the file what it is.
case "$TARGET" in
x86_64-apple-darwin) want="x86_64" ;;
aarch64-apple-darwin) want="arm64" ;;
*) want="" ;;
esac
if [ -n "$want" ]; then
got=$(file -b "target/${TARGET}/release/mossaic-art")
case "$got" in
*"$want"*) echo "architecture check: $want — $got" ;;
*) echo "::error::built for $TARGET but the binary is: $got"; exit 1 ;;
esac
fi

echo "ARCHIVE=$archive" >> "$GITHUB_ENV"
echo "ALIAS=$alias" >> "$GITHUB_ENV"

Expand Down
15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,21 @@ listed under a **Changed** or **Removed** heading.

### Fixed

- **The Intel-Mac binary is cross-compiled from Apple silicon** rather than
built on a `macos-13` runner. Xcode's toolchain and SDK are universal, so an
arm64 Mac produces an x86-64 binary with nothing but `rustup target add` —
no sysroot, no linker configuration.

The Intel runners are being wound down and it shows: on the v0.6.2 release
this leg sat queued for forty-five minutes while every other target finished
inside ninety seconds. A target nobody can schedule is a target that
silently stops shipping.

The job now asks `file` what it actually built, and fails if the answer is
not the architecture the target names — a cross-build that quietly produced
the host's architecture would pass every other check here and fail on the
first machine that downloaded it.

- **The README no longer promises Homebrew.** The line went in ahead of the
tap existing, on the assumption that the tap would follow within the hour.
It has not yet, and an install command that does not work is worse than one
Expand Down