Handles are valid upon construction #75
Workflow file for this run
This file contains hidden or 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
| # yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | |
| name: "CodeQL - Analyze (C++, Python, Actions)" | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| schedule: | |
| - cron: '0 3 * * 0' # weekly (UTC) — adjust as needed | |
| workflow_dispatch: | |
| permissions: | |
| actions: read | |
| contents: read | |
| security-events: write | |
| env: | |
| BUILD_TYPE: RelWithDebInfo | |
| CPP_COMPILER: g++ | |
| jobs: | |
| codeql: | |
| name: Analyze ${{ matrix.language }} with CodeQL | |
| runs-on: ubuntu-24.04 | |
| container: | |
| image: ghcr.io/framework-r-d/phlex-ci:latest | |
| strategy: | |
| fail-fast: false | |
| matrix: # Necessry to disable yaml-language-server warning | |
| language: ['cpp', 'python', 'actions'] | |
| timeout-minutes: 120 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| path: phlex-src | |
| fetch-depth: 0 | |
| - name: Setup build environment | |
| uses: ./phlex-src/.github/actions/setup-build-env | |
| with: | |
| build-path: phlex-build | |
| - name: Initialize CodeQL | |
| uses: github/codeql-action/init@v4 | |
| with: | |
| languages: ${{ matrix.language }} | |
| config-file: phlex-src/.github/codeql/codeql-config.yml | |
| source-root: phlex-src | |
| build-mode: ${{ matrix.language == 'cpp' && 'manual' || 'none' }} | |
| - name: Configure and build (C++ only) | |
| if: matrix.language == 'cpp' | |
| run: | | |
| . /entrypoint.sh | |
| cd "$GITHUB_WORKSPACE/phlex-build" | |
| # For reasons unknown, CodeQL's choice of LD_PRELOAD needs to | |
| # be corrected | |
| export LD_PRELOAD="$SEMMLE_PRELOAD_libtrace64" | |
| echo "LD_PRELOAD=$LD_PRELOAD" | |
| cmake --preset=default -S "$GITHUB_WORKSPACE/phlex-src" \ | |
| -B "$GITHUB_WORKSPACE/phlex-build" -GNinja \ | |
| -DCMAKE_BUILD_TYPE="$BUILD_TYPE" \ | |
| -DCMAKE_CXX_COMPILER="$CPP_COMPILER" \ | |
| -DPHLEX_USE_FORM=TRUE \ | |
| -DFORM_USE_ROOT_STORAGE=TRUE || exit | |
| cmake --build . || exit | |
| # Run CodeQL analysis (uploads results to code scanning) | |
| - name: Perform CodeQL Analysis | |
| uses: github/codeql-action/analyze@v4 | |
| with: | |
| checkout_path: phlex-src | |
| category: ${{ matrix.language }} |