From b75b14f1618f44580ed5f40e9fa5edf4adf4063f Mon Sep 17 00:00:00 2001 From: tiero <3596602+tiero@users.noreply.github.com> Date: Tue, 17 Oct 2023 19:44:10 +0200 Subject: [PATCH] fix: cross-compile for Apple Silicon --- .github/workflows/release.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 78968fc..2b61ecb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -104,15 +104,22 @@ jobs: target/ key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} restore-keys: ${{ runner.os }}-cargo- + + - name: Add aarch64 target + run: rustup target add aarch64-apple-darwin - - name: Build + - name: Build for Mac with Intel run: cargo build --release + - name: Build for Apple Silicon + run: cargo build --release --target=aarch64-apple-darwin + - name: "Move to outputs/ folder" run: | mkdir outputs cp target/release/whisper outputs/whisper-darwin-x86_64 - + cp target/aarch64-apple-darwin/release/whisper outputs/whisper-darwin-aarch64 + - name: Upload to temporary storage uses: actions/upload-artifact@master with: