Build VF2 Kernel #554
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build VF2 Kernel | |
permissions: | |
contents: write | |
on: | |
#push: | |
# branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
workflow_dispatch: | |
workflow_run: | |
workflows: [Scheduled Merge Remote Action2] | |
types: [completed] | |
workflow_call: | |
# secrets: | |
# GPG_PRIVATE_KEY: | |
# description: 'GPG Private Key' | |
# required: True | |
# GPG_PUBLIC_KEY: | |
# description: 'GPG Public Key' | |
# required: True | |
# GPG_PRIVATE_KEY_PASSWORD: | |
# description: 'GPG Private Key Password' | |
# required: True | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
#runs-on: self-hosted | |
container: | |
image: tuxmake/riscv_gcc:latest | |
options: --user root | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
ref: master | |
fetch-depth: 1 | |
- name: Install dependencies | |
run: apt update && apt install -y build-essential debhelper #gcc-riscv64-linux-gnu | |
- name: ccache | |
uses: hendrikmuhs/[email protected] | |
- name: Set git config options | |
run: git config --global --add safe.directory $(pwd) | |
- name: Make visionfive2_defconfig | |
run: | | |
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH" | |
make CROSS_COMPILE=riscv64-linux-gnu- ARCH=riscv visionfive2_docker_defconfig | |
- name: Make kernel | |
run: | | |
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH" | |
make CROSS_COMPILE=riscv64-linux-gnu- ARCH=riscv -j`nproc` | |
- name: Make modules | |
run: | | |
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH" | |
make CROSS_COMPILE=riscv64-linux-gnu- ARCH=riscv -j`nproc` modules | |
- name: Build .deb packages | |
run: | | |
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH" | |
make CROSS_COMPILE=riscv64-linux-gnu- ARCH=riscv -j`nproc` bindeb-pkg | |
- name: Copy .deb to /tmp | |
run: | | |
rm -rf /tmp/* | |
cp ../*.deb /tmp/ | |
# - name: Cache Debs | |
# id: cache-debs-save | |
# uses: actions/cache@v3 | |
# with: | |
# path: /tmp/ | |
# key: "deb-cache-${{ github.run_id }}" | |
- name: 'Upload Artifact' | |
uses: actions/upload-artifact@v3 | |
with: | |
name: compiled_vf2_debs | |
path: /tmp/*.deb | |
retention-days: 5 | |
- name: Push Git changes | |
run: | | |
git config --global user.email "[email protected]" | |
git config --global user.name "Merge Upstream Action" | |
git add -f .version | |
git commit -m "Updating version" --no-edit | |
git push origin master | |
#Update_Repo: | |
# if: ${{ always() && contains(join(needs.*.result, ','), 'success') }} | |
# needs: [build] | |
# uses: ./.github/workflows/update_repo.yml | |
# secrets: | |
# GPG_PRIVATE_KEY: "${{ secrets.GPG_PRIVATE_KEY }}" | |
# GPG_PUBLIC_KEY: "${{ secrets.GPG_PUBLIC_KEY }}" | |
# GPG_PRIVATE_KEY_PASSWORD: "${{ secrets.GPG_PRIVATE_KEY_PASSWORD }}" | |
#Release_Kernel: | |
# if: ${{ always() && contains(join(needs.*.result, ','), 'success') }} | |
# needs: [build] | |
# uses: ./.github/workflows/release_vf2_kernel.yml |