mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-08-09 08:04:45 +00:00
Amethyst v1.13.1 (and every prior release) shipped only linux-x64 desktop
binaries — .deb, .rpm, .AppImage, .flatpak, .tar.gz. Same for the amy
CLI and geode relay. Users on aarch64 hardware (Pinebook, Ampere
Altra, Raspberry Pi 4/5, AWS Graviton, arm64 servers, arm64 Chromebooks
running crostini, etc.) can't install any of them.
This teaches the release matrix about arm64:
- Add `ubuntu-24.04-arm` legs to build-desktop, build-cli, and
build-geode. This is a standard, free public-repo GitHub-hosted
runner (4 CPU / 16 GB / 14 GB SSD / arm64) since early 2025. No
cross-compilation: jpackage / jlink / Compose Multiplatform 1.11
all produce host-native artifacts.
- Fetch the matching `appimagetool-<arch>.AppImage` from the same
1.9.0 release with an arch-specific SHA256 pin. `APPIMAGETOOL_URL`
becomes `APPIMAGETOOL_VERSION` + per-arch SHA256 env vars.
- Parametrize the portable tarball/zip filename by `matrix.arch`
(`amethyst-desktop-<ver>-linux-arm64.tar.gz` is now produced).
- Parametrize the Flatpak bundle filename and rewrite the manifest's
`GST_PLUGIN_SYSTEM_PATH` from `x86_64-linux-gnu` to
`aarch64-linux-gnu` on the arm64 leg. The Flathub-submission manifest
(`desktopApp/packaging/flatpak/flathub/`) still gates on
`only-arches: x86_64` — flipping that to include aarch64 is a
follow-up once a Flathub aarch64 build has been validated end-to-end.
- Make the `createReleaseAppImage` gradle task pick its host arch from
`System.getProperty("os.arch")` (amd64/x86_64 → `x86_64`, aarch64/
arm64 → `aarch64`). Same task, same command, drives both legs.
- Fix `desktopApp/packaging/appimage/AppRun` to compute the multiarch
library path from `uname -m` at launch time instead of hard-coding
`x86_64-linux-gnu`. One script works in both AppImages on the target
machine.
- Extend the desktop smoke test to run the release .deb build + launch
probe on `ubuntu-24.04-arm` too, so arch-specific ProGuard/jlink
breakage (missing native lib, arch-specific reflection root) is
caught at PR time.
- Update BUILDING.md and scripts/asset-name.sh docs with the new
arm64 asset names.
Follow-up assets published for the next tag push (v1.13.2+):
- amethyst-desktop-<ver>-linux-arm64.{deb,rpm,AppImage,flatpak,tar.gz}
- amy-<ver>-linux-arm64.{deb,rpm,tar.gz}
- geode-<ver>-linux-arm64.{deb,rpm,tar.gz}
Verification (local, before submitting):
- `python3 -c 'import yaml; yaml.safe_load(open(".github/workflows/create-release.yml"))'` — parses clean
- `bash -n scripts/asset-name.sh desktopApp/packaging/appimage/AppRun` — parses clean
- `actionlint` — reports only pre-existing shellcheck style hints; no new errors
- Confirmed `linuxdeploy-aarch64.AppImage` and
`appimagetool-aarch64.AppImage` exist under the same pinned release
tags used for x86_64; SHA256 recorded from a fresh download.
Not addressed (out of scope for this PR):
- Homebrew / winget bump workflows (`bump-homebrew*.yml`,
`bump-winget.yml`) — those consume the assets by name; the new arm64
filenames don't change any x86_64 name they already reference.
- Android arm64 continues to ship as before (already had it).
208 lines
8.0 KiB
Bash
Executable File
208 lines
8.0 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Single source of truth for Amethyst release asset naming.
|
|
#
|
|
# Three product lines share this contract:
|
|
# amethyst-desktop-<version>-<family>-<arch>.<ext> (Compose Desktop app)
|
|
# amy-<version>-<family>-<arch>.<ext> (Amy CLI — cli/ module)
|
|
# geode-<version>-<family>-<arch>.<ext> (geode relay — geode/ module)
|
|
#
|
|
# <version> = tag stripped of leading 'v' (e.g. "1.08.0")
|
|
# <family> = macos | windows | linux
|
|
# <arch> = x64 | arm64
|
|
# <ext> = dmg | msi | zip | deb | rpm | AppImage | flatpak | tar.gz
|
|
#
|
|
# Consumed by: .github/workflows/create-release.yml, .github/workflows/bump-*.yml,
|
|
# BUILDING.md, local release runbooks.
|
|
#
|
|
# Usage:
|
|
# source scripts/asset-name.sh
|
|
# collect_assets <family> <arch> <version> <dest_dir> # desktop
|
|
# collect_cli_assets <family> <arch> <version> <dest_dir> # amy CLI
|
|
#
|
|
# Expected examples:
|
|
# amethyst-desktop-1.08.0-macos-x64.dmg
|
|
# amethyst-desktop-1.08.0-macos-arm64.dmg
|
|
# amethyst-desktop-1.08.0-windows-x64.msi
|
|
# amethyst-desktop-1.08.0-windows-x64.zip
|
|
# amethyst-desktop-1.08.0-linux-x64.deb
|
|
# amethyst-desktop-1.08.0-linux-x64.rpm
|
|
# amethyst-desktop-1.08.0-linux-x64.AppImage
|
|
# amethyst-desktop-1.08.0-linux-x64.flatpak
|
|
# amethyst-desktop-1.08.0-linux-x64.tar.gz
|
|
# amethyst-desktop-1.08.0-linux-arm64.deb
|
|
# amethyst-desktop-1.08.0-linux-arm64.rpm
|
|
# amethyst-desktop-1.08.0-linux-arm64.AppImage
|
|
# amethyst-desktop-1.08.0-linux-arm64.flatpak
|
|
# amethyst-desktop-1.08.0-linux-arm64.tar.gz
|
|
# amy-1.08.0-macos-arm64.tar.gz
|
|
# amy-1.08.0-macos-x64.tar.gz
|
|
# amy-1.08.0-linux-x64.tar.gz
|
|
# amy-1.08.0-linux-x64.deb
|
|
# amy-1.08.0-linux-x64.rpm
|
|
# amy-1.08.0-linux-arm64.tar.gz
|
|
# amy-1.08.0-linux-arm64.deb
|
|
# amy-1.08.0-linux-arm64.rpm
|
|
# geode-1.08.0-macos-arm64.tar.gz
|
|
# geode-1.08.0-linux-x64.tar.gz
|
|
# geode-1.08.0-linux-x64.deb
|
|
# geode-1.08.0-linux-x64.rpm
|
|
# geode-1.08.0-linux-arm64.tar.gz
|
|
# geode-1.08.0-linux-arm64.deb
|
|
# geode-1.08.0-linux-arm64.rpm
|
|
#
|
|
# Two assets break the family/arch shape on purpose: the no-JRE jar bundles for
|
|
# Homebrew-core are pure JVM bytecode (no bundled runtime), so a single
|
|
# platform-independent artifact serves every OS:
|
|
# amy-1.08.0-jvm.tar.gz
|
|
# geode-1.08.0-jvm.tar.gz
|
|
# They are packaged inline in create-release.yml (linux leg), not via the helpers
|
|
# below, since they have no <family>/<arch> dimension.
|
|
|
|
set -euo pipefail
|
|
|
|
# Print the canonical asset filename for a given family/arch/version/extension.
|
|
# Usage: asset_name <family> <arch> <version> <ext>
|
|
asset_name() {
|
|
local family="$1" arch="$2" version="$3" ext="$4"
|
|
printf 'amethyst-desktop-%s-%s-%s.%s' "$version" "$family" "$arch" "$ext"
|
|
}
|
|
|
|
# CLI variant of asset_name — same shape, different product prefix.
|
|
# Usage: cli_asset_name <family> <arch> <version> <ext>
|
|
cli_asset_name() {
|
|
local family="$1" arch="$2" version="$3" ext="$4"
|
|
printf 'amy-%s-%s-%s.%s' "$version" "$family" "$arch" "$ext"
|
|
}
|
|
|
|
# geode relay variant of asset_name — same shape, different product prefix.
|
|
# Usage: geode_asset_name <family> <arch> <version> <ext>
|
|
geode_asset_name() {
|
|
local family="$1" arch="$2" version="$3" ext="$4"
|
|
printf 'geode-%s-%s-%s.%s' "$version" "$family" "$arch" "$ext"
|
|
}
|
|
|
|
# Copy + rename build outputs into <dest_dir> using the canonical naming scheme.
|
|
# Usage: collect_assets <family> <arch> <version> <dest_dir>
|
|
# Expects build outputs under desktopApp/build/... (Compose binaries + custom tasks + portable archives).
|
|
collect_assets() {
|
|
local family="$1" arch="$2" version="$3" dest="$4"
|
|
# Normalize internal matrix family aliases to canonical asset-name families.
|
|
[[ "$family" == "linux-portable" ]] && family="linux"
|
|
mkdir -p "$dest"
|
|
shopt -s nullglob
|
|
|
|
# Compose Desktop jpackage outputs (main-release/<format>/*.ext)
|
|
local src ext base dst
|
|
for src in \
|
|
desktopApp/build/compose/binaries/main-release/dmg/*.dmg \
|
|
desktopApp/build/compose/binaries/main-release/msi/*.msi \
|
|
desktopApp/build/compose/binaries/main-release/deb/*.deb \
|
|
desktopApp/build/compose/binaries/main-release/rpm/*.rpm \
|
|
desktopApp/build/appimage/*.AppImage \
|
|
desktopApp/build/flatpak/*.flatpak \
|
|
desktopApp/build/portable/*.tar.gz \
|
|
desktopApp/build/portable/*.zip \
|
|
; do
|
|
[ -f "$src" ] || continue
|
|
base="$(basename "$src")"
|
|
case "$base" in
|
|
*.tar.gz) ext="tar.gz" ;;
|
|
*) ext="${base##*.}" ;;
|
|
esac
|
|
dst="$dest/$(asset_name "$family" "$arch" "$version" "$ext")"
|
|
cp "$src" "$dst"
|
|
echo "Collected: $dst"
|
|
done
|
|
shopt -u nullglob
|
|
}
|
|
|
|
# Copy + rename amy CLI build outputs into <dest_dir> using the canonical
|
|
# amy-<version>-<family>-<arch>.<ext> scheme.
|
|
#
|
|
# Expected inputs:
|
|
# cli/build/amy-image/amy/ flat app-image built by :cli:amyImage
|
|
# (bin/amy + lib/*.jar + runtime/)
|
|
# cli/build/jpackage/*.deb from :cli:jpackageDeb (Linux only)
|
|
# cli/build/jpackage/*.rpm from :cli:jpackageRpm (Linux only)
|
|
#
|
|
# Usage: collect_cli_assets <family> <arch> <version> <dest_dir>
|
|
collect_cli_assets() {
|
|
local family="$1" arch="$2" version="$3" dest="$4"
|
|
mkdir -p "$dest"
|
|
local abs_dest
|
|
abs_dest="$(cd "$dest" && pwd)"
|
|
shopt -s nullglob
|
|
|
|
# 1. Tar the flat app-image into amy-<version>-<family>-<arch>.tar.gz.
|
|
# This is the portable-across-OS asset — macOS runners produce only
|
|
# this one.
|
|
local app_image="cli/build/amy-image/amy"
|
|
if [ -d "$app_image" ]; then
|
|
local tarball="$abs_dest/$(cli_asset_name "$family" "$arch" "$version" tar.gz)"
|
|
( cd "$(dirname "$app_image")" && tar czf "$tarball" "$(basename "$app_image")" )
|
|
echo "Collected: $tarball"
|
|
fi
|
|
|
|
# 2. Linux native installers (.deb, .rpm). jpackage writes them directly
|
|
# to cli/build/jpackage/ with its own naming, so we re-copy under the
|
|
# canonical scheme.
|
|
local src base ext dst
|
|
for src in \
|
|
cli/build/jpackage/*.deb \
|
|
cli/build/jpackage/*.rpm \
|
|
; do
|
|
[ -f "$src" ] || continue
|
|
base="$(basename "$src")"
|
|
ext="${base##*.}"
|
|
dst="$abs_dest/$(cli_asset_name "$family" "$arch" "$version" "$ext")"
|
|
cp "$src" "$dst"
|
|
echo "Collected: $dst"
|
|
done
|
|
shopt -u nullglob
|
|
}
|
|
|
|
# Copy + rename geode relay build outputs into <dest_dir> using the canonical
|
|
# geode-<version>-<family>-<arch>.<ext> scheme.
|
|
#
|
|
# Expected inputs:
|
|
# geode/build/geode-image/geode/ flat app-image built by :geode:geodeImage
|
|
# (bin/geode + lib/*.jar + runtime/ + share/)
|
|
# geode/build/jpackage/*.deb from :geode:jpackageDeb (Linux only)
|
|
# geode/build/jpackage/*.rpm from :geode:jpackageRpm (Linux only)
|
|
#
|
|
# Usage: collect_geode_assets <family> <arch> <version> <dest_dir>
|
|
collect_geode_assets() {
|
|
local family="$1" arch="$2" version="$3" dest="$4"
|
|
mkdir -p "$dest"
|
|
local abs_dest
|
|
abs_dest="$(cd "$dest" && pwd)"
|
|
shopt -s nullglob
|
|
|
|
# 1. Tar the flat app-image into geode-<version>-<family>-<arch>.tar.gz.
|
|
# This is the portable-across-OS asset — macOS runners produce only
|
|
# this one.
|
|
local app_image="geode/build/geode-image/geode"
|
|
if [ -d "$app_image" ]; then
|
|
local tarball="$abs_dest/$(geode_asset_name "$family" "$arch" "$version" tar.gz)"
|
|
( cd "$(dirname "$app_image")" && tar czf "$tarball" "$(basename "$app_image")" )
|
|
echo "Collected: $tarball"
|
|
fi
|
|
|
|
# 2. Linux native installers (.deb, .rpm). jpackage writes them directly
|
|
# to geode/build/jpackage/ with its own naming, so we re-copy under the
|
|
# canonical scheme.
|
|
local src base ext dst
|
|
for src in \
|
|
geode/build/jpackage/*.deb \
|
|
geode/build/jpackage/*.rpm \
|
|
; do
|
|
[ -f "$src" ] || continue
|
|
base="$(basename "$src")"
|
|
ext="${base##*.}"
|
|
dst="$abs_dest/$(geode_asset_name "$family" "$arch" "$version" "$ext")"
|
|
cp "$src" "$dst"
|
|
echo "Collected: $dst"
|
|
done
|
|
shopt -u nullglob
|
|
}
|