diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index d97f287..57dee4c 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -22,14 +22,28 @@ jobs: - name: Install deps run: | brew install ffmpeg@5 - brew link ffmpeg@5 + + - name: Install Rust support for ARM64 & prepare environment + run: | + rustup target add aarch64-apple-darwin - name: Build run: | mkdir releases cargo build --release strip target/release/bliss-analyser - cp target/release/bliss-analyser releases/bliss-analyser + cp target/release/bliss-analyser releases/bliss-analyser-x86_64 + cargo build --target=aarch64-apple-darwin --release + strip target/aarch64-apple-darwin/release/bliss-analyser + cp target/aarch64-apple-darwin/release/bliss-analyser releases/bliss-analyser-arm64 + ls -alR /usr/local/Cellar/ + + - name: Build fat binary + run: | + lipo -create \ + -arch x86_64 releases/bliss-analyser-x86_64 \ + -arch arm64 releases/bliss-analyser-arm64 \ + -output releases/bliss-analyser - name: Upload artifacts uses: actions/upload-artifact@v2