Skip to content

Commit

Permalink
chore: Update Docker and rust workflow; add Rust Tests & Linting work…
Browse files Browse the repository at this point in the history
…flow
  • Loading branch information
KlementXV committed Aug 15, 2024
1 parent 72fdf5b commit b32e250
Showing 1 changed file with 0 additions and 73 deletions.
73 changes: 0 additions & 73 deletions .github/workflows/rust-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -189,79 +189,6 @@ jobs:
name: Build on ARM64 (Ubuntu 22.04)
needs: version
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true

- name: Setup Rust
run: |
curl https://sh.rustup.rs -sSf | sh -s -- -y
source "$HOME/.cargo/env"
rustup target add aarch64-unknown-linux-gnu
- name: Install dependencies
run: |
sudo apt-get update && sudo apt-get install -y \
musl-tools \
clang \
gcc-aarch64-linux-gnu \
g++-aarch64-linux-gnu \
libc6-dev \
libc6-dev-arm64-cross \
pkg-config \
libssl-dev:aarch64
- name: Configure cache
uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: release-${{ runner.os }}-cargo-aarch64-unknown-linux-gnu-${{ hashFiles('**/Cargo.lock') }}

- name: Build
run: |
env BINDGEN_EXTRA_CLANG_ARGS='--sysroot /usr/aarch64-linux-gnu' \
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=/usr/bin/aarch64-linux-gnu-gcc \
cargo build --release --target aarch64-unknown-linux-gnu
- name: Strip binary
run: strip target/aarch64-unknown-linux-gnu/release/${{ env.BINARY_NAME }}

- name: Package
run: |
rm -rf target/dist
mkdir -p target/dist
cp target/aarch64-unknown-linux-gnu/release/${{ env.BINARY_NAME }} target/dist/${{ env.BINARY_NAME }}-${{ needs.version.outputs.version }}-aarch64-unknown-linux-gnu
- name: Upload archive
uses: actions/upload-artifact@v4
with:
name: ${{ env.BINARY_NAME }}-${{ needs.version.outputs.version }}-aarch64-unknown-linux-gnu
path: target/dist/*

- name: Debug - Check file existence
run: ls -alh target/dist

- name: Upload release asset
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: target/dist/${{ env.BINARY_NAME }}-${{ needs.version.outputs.version }}-aarch64-unknown-linux-gnu
asset_name: ${{ env.BINARY_NAME }}-${{ needs.version.outputs.version }}-aarch64-unknown-linux-gnu
asset_content_type: application/octet-stream
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} name: Build on ARM64 (Ubuntu 22.04)
needs: version
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
Expand Down

0 comments on commit b32e250

Please sign in to comment.