| # SPDX-License-Identifier: GPL-2.0 |
| # |
| # Copyright (c) 2021 Canonical Ltd. |
| # Copyright (c) 2023 Linaro Ltd. |
| # Author: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> |
| # <krzk@kernel.org> |
| # |
| name: "CodeQL" |
| on: [push, pull_request, workflow_dispatch] |
| |
| jobs: |
| analyze: |
| name: Analyze |
| runs-on: ubuntu-latest |
| permissions: |
| actions: read |
| contents: read |
| security-events: write |
| |
| strategy: |
| fail-fast: false |
| matrix: |
| language: [ 'cpp', 'python' ] |
| |
| steps: |
| - name: Checkout repository |
| uses: actions/checkout@v3 |
| |
| - name: Initialize CodeQL |
| uses: github/codeql-action/init@v2 |
| with: |
| languages: ${{ matrix.language }} |
| |
| - name: Install additional packages |
| run: sudo ./ci/ubuntu.sh |
| |
| - name: Configure |
| run: ./bootstrap-configure |
| |
| - name: Compile |
| run: | |
| make -j$(nproc) |
| make check |
| |
| - name: Perform CodeQL Analysis |
| uses: github/codeql-action/analyze@v2 |