Skip to content

build: remove check for obsolete target #196

build: remove check for obsolete target

build: remove check for obsolete target #196

Workflow file for this run

name: Build and test all platforms
on:
pull_request:
push:
branches:
- main
paths-ignore:
- '**.md'
- .gitignore
workflow_dispatch:
jobs:
build-test:
name: ${{matrix.config.name}} ${{matrix.build_type}}
runs-on: ${{matrix.config.os}}
strategy:
fail-fast: false
matrix:
build_type: ["Debug", "Release"]
config:
- {
name: "Windows Latest MSVC ",
artifact: "windows-msvc.txz",
os: windows-latest,
shell: powershell,
generator: default,
cc: "cl", cxx: "cl"
}
- {
name: "Ubuntu Latest GCC ",
artifact: "ubuntu.txz",
os: ubuntu-latest,
shell: bash,
generator: default,
cc: "gcc", cxx: "g++"
}
- {
name: "Windows Latest MINGW ",
artifact: "windows-mingw.txz",
os: windows-latest,
shell: cmd,
generator: "MinGW Makefiles",
cc: "gcc", cxx: "g++"
}
#- {
# name: "macOS Latest Clang",
# artifact: "macos.txz",
# os: macos-latest,
# cc: "clang", cxx: "clang++"
# }
defaults:
run:
shell: ${{matrix.config.shell}}
env:
CC: ${{matrix.config.cc}}
CXX: ${{matrix.config.cxx}}
steps:
- uses: actions/checkout@v4
- name: Configure CMake (default generator)
working-directory: ${{github.workspace}}
if: ${{matrix.config.generator == 'default'}}
run: cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -B build/ src/
- name: Configure CMake (specific generator)
working-directory: ${{github.workspace}}
if: ${{matrix.config.generator != 'default'}}
run: cmake -G"${{matrix.config.generator}}" -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -B build/ src/
- name: Build
working-directory: ${{github.workspace}}
run: cmake --build build/ --config ${{matrix.build_type}}
- name: Test
working-directory: ${{github.workspace}}/build/test
run: ctest --output-on-failure -C ${{matrix.build_type}}
#- name: Pack
# working-directory: ${{github.workspace}}/build
# run: cmake -E tar -Jcfv ../${{matrix.build_type}}${{matrix.config.artifact}} .
#- name: Upload
# uses: actions/upload-artifact@v4
# with:
# path: ./${{matrix.build_type}}${{matrix.config.artifact}}
# name: ${{matrix.build_type}}${{matrix.config.artifact}}