name: Build aarch64 kernel
on: [pull_request, create]

jobs:
  build:
    if: github.event_name == 'pull_request'
    name: Build aarch64 kernel
    runs-on: ubuntu-latest
    strategy:
      matrix:
        rust:
          - stable
        target:
          - aarch64-unknown-linux-gnu
    steps:
      - name: Code checkout
        uses: actions/checkout@v2

      - name: Install dependencies
        run: sudo apt-get install -y make gcc bc bison flex elfutils python3-pyelftools curl patch libelf-dev

      - name: Build aarch64 kernel
        run: make
