Fix API changes in SFML 3 #619
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, pull_request, workflow_dispatch] | |
concurrency: | |
group: environment-${{github.ref}} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
build: | |
name: ${{ matrix.platform.name }} ${{ matrix.type.name }} | |
runs-on: ${{ matrix.platform.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
platform: | |
- { name: Windows VS2019 x86, os: windows-2019, flags: -AWin32 } | |
- { name: Windows VS2019 x64, os: windows-2019, flags: -Ax64 } | |
- { name: Windows VS2022 x86, os: windows-2022, flags: -AWin32 } | |
- { name: Windows VS2022 x64, os: windows-2022, flags: -Ax64 } | |
- { name: Windows ClangCL, os: windows-2022, flags: -T ClangCL } | |
- { name: Windows Clang, os: windows-2022, flags: -GNinja -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ } | |
- { name: Linux GCC, os: ubuntu-22.04, flags: -GNinja } | |
- { name: Linux Clang, os: ubuntu-22.04, flags: -GNinja -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ } | |
- { name: MacOS, os: macos-12, flags: -GNinja } | |
type: | |
- { name: Debug } | |
- { name: Release } | |
steps: | |
- name: Get CMake and Ninja | |
uses: lukka/get-cmake@latest | |
with: | |
ninjaVersion: latest | |
- name: Install Linux Dependencies | |
if: runner.os == 'Linux' | |
run: sudo apt-get update && sudo apt-get install libxrandr-dev libxcursor-dev libudev-dev libopenal-dev libflac-dev libvorbis-dev libgl1-mesa-dev libegl1-mesa-dev | |
- name: Checkout SFML | |
uses: actions/checkout@v4 | |
with: | |
repository: SFML/SFML | |
ref: 504b850f03c71385eed293ff5106f58c31423973 | |
path: SFML | |
- name: Configure SFML CMake | |
run: cmake -S SFML -B SFML/build -DCMAKE_INSTALL_PREFIX=SFML/install -DBUILD_SHARED_LIBS=TRUE -DSFML_BUILD_EXAMPLES=FALSE -DSFML_BUILD_TEST_SUITE=FALSE -DCMAKE_VERBOSE_MAKEFILE=ON ${{matrix.platform.flags}} -DCMAKE_BUILD_TYPE=${{matrix.type.name}} | |
- name: Build SFML | |
run: cmake --build SFML/build --config ${{matrix.type.name}} --target install | |
- name: Checkout CSFML | |
uses: actions/checkout@v4 | |
with: | |
path: CSFML | |
- name: Configure CSFML CMake | |
run: cmake -S CSFML -B CSFML/build -DCMAKE_INSTALL_PREFIX=CSFML/install -DBUILD_SHARED_LIBS=TRUE -DCSFML_BUILD_EXAMPLES=TRUE -DCSFML_BUILD_TEST_SUITE=TRUE -DCSFML_LINK_SFML_STATICALLY=FALSE -DSFML_DIR=$GITHUB_WORKSPACE/SFML/install/lib/cmake/SFML -DCMAKE_VERBOSE_MAKEFILE=ON -DWARNINGS_AS_ERRORS=TRUE ${{matrix.platform.flags}} -DCMAKE_BUILD_TYPE=${{matrix.type.name}} | |
- name: Build CSFML | |
run: cmake --build CSFML/build --config ${{matrix.type.name}} --target install | |
- name: Test | |
run: ctest --test-dir CSFML/build -C ${{matrix.type.name}} --output-on-failure |