Add example #28
Workflow file for this run
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: [ main ] | ||
paths-ignore: | ||
- '**.md' | ||
pull_request: | ||
branches: [ main ] | ||
paths-ignore: | ||
- '**.md' | ||
jobs: | ||
build: | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ windows-latest, macos-latest, ubuntu-latest ] | ||
type: [ Debug, Release ] | ||
features: [ { parent: OFF, initial: OFF }, { parent: ON, initial: OFF }, { parent: ON, initial: ON } ] | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Get latest CMake and Ninja | ||
uses: lukka/get-cmake@latest | ||
- name: CMake generate build for SMF library | ||
run: cmake -G Ninja -S . -B build -DCMAKE_BUILD_TYPE=${{ matrix.type }} -DSMF_ENABLE_EXAMPLES=ON -DSMF_ANCESTOR_SUPPORT=${{matrix.features.parent}} -DSMF_INITIAL_TRANSITION=${{matrix.features.initial}} | ||
- name: CMake build SMF library | ||
run: cmake --build build | ||
build_clang: | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ windows-latest, macos-latest, ubuntu-latest ] | ||
clang: [ '14.0', '15' ] | ||
type: [ Debug, Release ] | ||
features: [ { parent: OFF, initial: OFF }, { parent: ON, initial: OFF }, { parent: ON, initial: ON } ] | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Install LLVM and Clang - ${{ matrix.clang }} | ||
uses: KyleMayes/install-llvm-action@v1 | ||
with: | ||
version: ${{ matrix.clang }} | ||
- name: Get latest CMake and Ninja | ||
uses: lukka/get-cmake@latest | ||
- name: CMake generate build for SMF library | ||
run: cmake -G Ninja -S . -B build -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_BUILD_TYPE=${{ matrix.type }} -DSMF_ENABLE_EXAMPLES=ON -DSMF_ANCESTOR_SUPPORT=${{matrix.features.parent}} -DSMF_INITIAL_TRANSITION=${{matrix.features.initial}} | ||
- name: CMake build SMF library | ||
run: cmake --build build | ||
build_msvc: | ||
runs-on: windows-latest | ||
matrix: | ||
type: [ Debug, Release ] | ||
features: [ { parent: OFF, initial: OFF }, { parent: ON, initial: OFF }, { parent: ON, initial: ON } ] | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Get latest CMake and Ninja | ||
uses: lukka/get-cmake@latest | ||
- name: CMake generate build for SMF library | ||
run: cmake -G "Visual Studio 17 2022" -S . -B build -DCMAKE_BUILD_TYPE=${{ matrix.type }} -DSMF_ENABLE_EXAMPLES=ON -DSMF_ANCESTOR_SUPPORT=${{matrix.features.parent}} -DSMF_INITIAL_TRANSITION=${{matrix.features.initial}} | ||
- name: CMake build SMF library | ||
run: cmake --build build |