Skip to content

Commit a2d2ba1

Browse files
committed
chore: update dist, cross-compile
Swap to cross-compiling to aarch64-unknown-linux targets.
1 parent a6a33bd commit a2d2ba1

File tree

2 files changed

+19
-7
lines changed

2 files changed

+19
-7
lines changed

.github/workflows/release.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
# we specify bash to get pipefail; it guards against the `curl` command
6464
# failing. otherwise `sh` won't catch that `curl` returned non-0
6565
shell: bash
66-
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.25.1/cargo-dist-installer.sh | sh"
66+
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.26.0-prerelease.3/cargo-dist-installer.sh | sh"
6767
- name: Cache dist
6868
uses: actions/upload-artifact@v4
6969
with:
@@ -107,6 +107,7 @@ jobs:
107107
# - N "local" tasks that build each platform's binaries and platform-specific installers
108108
matrix: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix }}
109109
runs-on: ${{ matrix.runner }}
110+
container: ${{ matrix.container && matrix.container.image || null }}
110111
env:
111112
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
112113
BUILD_MANIFEST_NAME: target/distrib/${{ join(matrix.targets, '-') }}-dist-manifest.json
@@ -117,8 +118,15 @@ jobs:
117118
- uses: actions/checkout@v4
118119
with:
119120
submodules: recursive
121+
- name: Install Rust non-interactively if not already installed
122+
if: ${{ matrix.container }}
123+
run: |
124+
if ! command -v cargo > /dev/null 2>&1; then
125+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
126+
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
127+
fi
120128
- name: Install dist
121-
run: ${{ matrix.install_dist }}
129+
run: ${{ matrix.install_dist.run }}
122130
# Get the dist-manifest
123131
- name: Fetch local artifacts
124132
uses: actions/download-artifact@v4
@@ -143,7 +151,7 @@ jobs:
143151
run: |
144152
# Parse out what we just built and upload it to scratch storage
145153
echo "paths<<EOF" >> "$GITHUB_OUTPUT"
146-
jq --raw-output ".upload_files[]" dist-manifest.json >> "$GITHUB_OUTPUT"
154+
dist print-upload-files-from-manifest --manifest dist-manifest.json >> "$GITHUB_OUTPUT"
147155
echo "EOF" >> "$GITHUB_OUTPUT"
148156
149157
cp dist-manifest.json "$BUILD_MANIFEST_NAME"

dist-workspace.toml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ members = ["cargo:."]
44
# Config for 'dist'
55
[dist]
66
# The preferred dist version to use in CI (Cargo.toml SemVer syntax)
7-
cargo-dist-version = "0.25.1"
7+
cargo-dist-version = "0.26.0-prerelease.3"
88
# CI backends to support
99
ci = "github"
1010
# The installers to generate for each app
@@ -28,6 +28,10 @@ install-updater = true
2828
# Path that installers should place binaries in
2929
install-path = "CARGO_HOME"
3030

31-
[dist.github-custom-runners]
32-
aarch64-unknown-linux-gnu = "buildjet-8vcpu-ubuntu-2204-arm"
33-
aarch64-unknown-linux-musl = "buildjet-8vcpu-ubuntu-2204-arm"
31+
[dist.github-custom-runners.aarch64-unknown-linux-gnu.container]
32+
image = "quay.io/pypa/manylinux_2_28_x86_64"
33+
host = "x86_64-unknown-linux-musl"
34+
35+
[dist.github-custom-runners.aarch64-unknown-linux-musl.container]
36+
image = "quay.io/pypa/manylinux_2_28_x86_64"
37+
host = "x86_64-unknown-linux-musl"

0 commit comments

Comments
 (0)