自動インストール設定の追加 #69
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: CI | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- '.github/workflows/driver-cross-build.yml' | |
- '.test/bin/**' | |
- '.test/lint.sh' | |
- 'src/drivers/**' | |
pull_request: | |
types: [opened, synchronize] | |
paths: | |
- '.github/workflows/driver-cross-build.yml' | |
- '.test/bin/**' | |
- '.test/lint.sh' | |
- 'src/drivers/**' | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-python@v2 | |
with: | |
python-version: '3.x' | |
- name: Lint | |
run: | | |
./.test/lint.sh | |
build: | |
needs: lint | |
strategy: | |
fail-fast: false | |
matrix: | |
env: | |
- { RPI_LINUX_VER: rpi-4.1.y, CONFIG_FILE: config-4.1.21-v7+, RPI_LINUX_COMMIT_HASH: ff45bc0, GCC_VER: 4.8 } | |
- { RPI_LINUX_VER: rpi-4.4.y, CONFIG_FILE: config-4.4.38-v7+, RPI_LINUX_COMMIT_HASH: c95b7f1, GCC_VER: 4.8 } | |
- { RPI_LINUX_VER: rpi-4.14.y, CONFIG_FILE: config-4.14.34-v7+, RPI_LINUX_COMMIT_HASH: f70eae4, GCC_VER: 4.8 } | |
- { RPI_LINUX_VER: rpi-5.4.y, CONFIG_FILE: config-5.4.83-v7+, RPI_LINUX_COMMIT_HASH: 76c49e6, GCC_VER: 6.3 } | |
- { RPI_LINUX_VER: rpi-5.4.y, CONFIG_FILE: config-5.4.83-v7+, RPI_LINUX_COMMIT_HASH: 76c49e6, GCC_VER: 8.3 } | |
- { RPI_LINUX_VER: rpi-5.10.y, CONFIG_FILE: config-5.10.11-v7+, RPI_LINUX_COMMIT_HASH: 6af8ae3, GCC_VER: 6.3 } | |
- { RPI_LINUX_VER: rpi-5.10.y, CONFIG_FILE: config-5.10.11-v7+, RPI_LINUX_COMMIT_HASH: 6af8ae3, GCC_VER: 8.3 } | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install cross-build settings | |
id: gcc | |
env: | |
GCC_VER: ${{ matrix.env.GCC_VER }} | |
SRC_DIR: ${{ github.workspace }} | |
run: | | |
source ./.test/step0.sh | |
prepare_cross_compiler | |
echo "::set-output name=path::${CROSS_COMPILE_PATH}" | |
- name: Install kernel headers | |
env: | |
RPI_LINUX_VER: ${{ matrix.env.RPI_LINUX_VER }} | |
CONFIG_FILE: ${{ matrix.env.CONFIG_FILE }} | |
RPI_LINUX_COMMIT_HASH: ${{ matrix.env.RPI_LINUX_COMMIT_HASH }} | |
GCC_VER: ${{ matrix.env.GCC_VER }} | |
CROSS_COMPILE_PATH: ${{ steps.gcc.outputs.path }} | |
SRC_DIR: ${{ github.workspace }} | |
run: | | |
source ./.test/step1.sh | |
install_kernel_headers | |
- name: Build kernel module | |
env: | |
CROSS_COMPILE_PATH: ${{ steps.gcc.outputs.path }} | |
SRC_DIR: ${{ github.workspace }} | |
run: | | |
source ./.test/step2.sh | |
build_kernel_module | |