From 6e4a889a105862d8a10acac38088c4f4267b8f87 Mon Sep 17 00:00:00 2001 From: Vladislav Drozdov <90255521+prplV@users.noreply.github.com> Date: Mon, 12 May 2025 18:20:35 +0300 Subject: [PATCH] Create rust_riscv_build.yml --- .github/workflows/rust_riscv_build.yml | 37 ++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/rust_riscv_build.yml diff --git a/.github/workflows/rust_riscv_build.yml b/.github/workflows/rust_riscv_build.yml new file mode 100644 index 0000000..728baa7 --- /dev/null +++ b/.github/workflows/rust_riscv_build.yml @@ -0,0 +1,37 @@ +name: Rust riscv64 build + +on: + push: + branches: [ master , rc ] + pull_request: + branches: [ master , rc ] + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Install dependencies + run: sudo apt-get update && sudo apt-get install -y libssl-dev pkg-config build-essential gcc-riscv64-unknown-elf gcc-riscv64-linux-gnu binutils-riscv64-linux-gnu + + - name: Set up Rust + uses: dtolnay/rust-toolchain@stable + with: + toolchain: stable + + - name: Cache dependencies + uses: actions/cache@v4 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + restore-keys: | + ${{ runner.os }}-cargo- + + - name: Build x86_64-unknown-linux-gnu + run: cargo riscv64 --verbose