ci: common kernel build and embed ksud (#127)
This commit is contained in:
41
.github/workflows/build-ksud.yml
vendored
41
.github/workflows/build-ksud.yml
vendored
@@ -1,10 +1,10 @@
|
||||
name: Build KSUD
|
||||
on:
|
||||
workflow_call:
|
||||
push:
|
||||
branches: [ "main" ]
|
||||
branches: [ "main", "ci" ]
|
||||
paths:
|
||||
- '.github/workflows/build-ksud.yml'
|
||||
- '.github/workflows/ksud.yml'
|
||||
- 'userspace/ksud/**'
|
||||
pull_request:
|
||||
branches: [ "main" ]
|
||||
@@ -17,37 +17,6 @@ jobs:
|
||||
include:
|
||||
- target: aarch64-linux-android
|
||||
- target: x86_64-linux-android
|
||||
name: Build KSUD
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Set up cargo cache
|
||||
uses: actions/cache@v3
|
||||
continue-on-error: false
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/bin/
|
||||
~/.cargo/registry/index/
|
||||
~/.cargo/registry/cache/
|
||||
~/.cargo/git/db/
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||
restore-keys: ${{ runner.os }}-cargo-
|
||||
- name: Set up ksud build cache
|
||||
uses: actions/cache@v3
|
||||
continue-on-error: false
|
||||
with:
|
||||
path: ./userspace/ksud/target/
|
||||
key: ${{ runner.os }}-ksud-${{ hashFiles('**/Cargo.lock') }}-${{ matrix.target }}
|
||||
restore-keys: ${{ runner.os }}-ksud-
|
||||
- name: Build ksud
|
||||
uses: actions-rs/cargo@v1
|
||||
with:
|
||||
use-cross: true
|
||||
command: build
|
||||
args: --target ${{ matrix.target }} --release --manifest-path ./userspace/ksud/Cargo.toml
|
||||
- name: Upload ksud artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: ksud-${{ matrix.target }}
|
||||
path: ./userspace/ksud/target/**/release/ksud
|
||||
|
||||
uses: ./.github/workflows/ksud.yml
|
||||
with:
|
||||
target: ${{ matrix.target }}
|
||||
Reference in New Issue
Block a user