Hopefully this is the right time, but I guess we'll have to see the r… #258
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_cmake | |
on: | |
workflow_dispatch: | |
push: | |
paths: | |
- "do.py" | |
- ".github/workflows/cmake.yml" | |
- "code-experiments/build/c/CMakeLists.txt" | |
- "code-experiments/src/**.c" | |
- "code-experiments/src/**.h" | |
pull_request: | |
branches: [ master, development ] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
strategy: | |
matrix: | |
build_type: [Release, Debug] | |
os: [ubuntu-latest, windows-latest] | |
runs-on: ${{matrix.os}} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Build C amalgamation | |
run: python ${{github.workspace}}/do.py amalgamate-c | |
- name: Configure CMake | |
run: cmake -S ${{github.workspace}}/code-experiments/build/c/ -B build/ -DCMAKE_BUILD_TYPE=${{matrix.build_type}} | |
- name: Build | |
run: cmake --build build/ --config ${{matrix.build_type}} |