diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ac1338d..cc15cda 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -51,15 +51,15 @@ jobs: run: rustup update stable && rustup default stable && rustup target add ${{ matrix.rust-target }} - run: cargo build --release --target ${{ matrix.rust-target }} if: ${{ ! matrix.cross }} - - run: sudo dpkg --add-architecture arm64 && sudo apt-get update && sudo apt-get install -y libssl-dev:arm64 - if: ${{ matrix.cross }} - run: cargo install cross if: ${{ matrix.cross }} - run: cross build --release --target ${{ matrix.rust-target }} if: ${{ matrix.cross }} - - run: tar -czvf sprocket-${{ matrix.rust-target }}.tar.gz -C ./target/${{ matrix.rust-target }}/release sprocket + - run: tar -czvf sprocket-${{ matrix.rust-target }}.tar.gz sprocket + working-directory: ./target/${{ matrix.rust-target }}/release if: matrix.os != 'windows-latest' - - run: cd ./target/${{ matrix.rust-target }}/release && 7z a sprocket-${{ matrix.rust-target }}.zip sprocket.exe + - run: 7z a sprocket-${{ matrix.rust-target }}.zip sprocket.exe + working-directory: ./target/${{ matrix.rust-target }}/release if: matrix.os == 'windows-latest' - name: Update the GH release with the new artifact uses: softprops/action-gh-release@v2 diff --git a/Cargo.toml b/Cargo.toml index 29f49ce..70d6c1e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,3 +27,10 @@ tokio = { version = "1.39.1", features = ["full"] } tracing-log = "0.2.0" indicatif = "0.17.8" clap-verbosity-flag = "2.2.1" + +# Install openssl for the linux arm64 build +[workspace.metadata.cross.target.aarch64-unknown-linux-gnu] +pre-build = [ + "dpkg --add-architecture $CROSS_DEB_ARCH", + "apt-get update && apt-get --assume-yes install libssl-dev:$CROSS_DEB_ARCH" +]