ci: build lkm only if needed while building manager

This commit is contained in:
5ec1cff
2025-01-27 14:09:45 +08:00
parent c5ec2ff94b
commit 3d35845df3
4 changed files with 188 additions and 17 deletions

View File

@@ -9,6 +9,10 @@ on:
required: false
type: string
default: ubuntu-latest
pull_lkm:
required: false
type: boolean
default: true
pack_lkm:
required: false
type: boolean
@@ -25,18 +29,27 @@ jobs:
with:
fetch-depth: 0
- name: Download Pre-built LKMs
if: ${{ inputs.pack_lkm }}
- name: Pull lkms from branch
if: ${{ inputs.pack_lkm && inputs.pull_lkm }}
uses: actions/checkout@v4
with:
ref: lkm
path: lkm
- name: Prepare LKM fies
if: ${{ inputs.pack_lkm }}
- name: Download lkms from artifacts
if: ${{ inputs.pack_lkm && !inputs.pull_lkm }}
uses: actions/download-artifact@v4
- name: Prepare LKM files
if: ${{ inputs.pack_lkm && inputs.pull_lkm }}
run: |
cp lkm/*_kernelsu.ko ./userspace/ksud/bin/aarch64/
- name: Prepare LKM files
if: ${{ inputs.pack_lkm && !inputs.pull_lkm }}
run: |
cp android*-lkm/*_kernelsu.ko ./userspace/ksud/bin/aarch64/
- name: Setup rustup
run: |
rustup update stable