@@ -537,3 +537,107 @@ jobs:
537
537
- name : Execute style checker
538
538
run : python ./utils/check_code_style.py
539
539
540
+
541
+ # CI runs to test the CMake build system.
542
+
543
+ build_ubuntu_cmake :
544
+ needs : changed
545
+ if : ${{ needs.changed.outputs.game_code == 'true' || needs.changed.outputs.unit_tests == 'true' || needs.changed.outputs.integration_tests == 'true' || needs.changed.outputs.cmake_files == 'true' }}
546
+ runs-on : ubuntu-latest
547
+ steps :
548
+ - uses : actions/checkout@v3
549
+ with :
550
+ submodules : true
551
+ - name : Install development dependencies
552
+ run : |
553
+ sudo rm /etc/apt/sources.list.d/* && sudo dpkg --clear-avail # Speed up installation and get rid of unwanted lists
554
+ sudo apt update
555
+ sudo apt install -y --no-install-recommends libxmu-dev libxi-dev libgl-dev libglu1-mesa-dev libgles2-mesa-dev libwayland-dev libxkbcommon-dev libegl1-mesa-dev libosmesa6 mesa-utils libglvnd-dev
556
+ - uses : lukka/get-cmake@latest
557
+ - uses : lukka/run-vcpkg@v10
558
+ - uses : lukka/run-cmake@v10
559
+ with :
560
+ configurePreset : ' linux-ci'
561
+ buildPreset : ' linux-ci'
562
+ testPreset : ' linux-ci'
563
+ - name : Run Benchmarks
564
+ run : ctest --preset linux-ci-benchmark
565
+ - name : Prevent saving cache on failure
566
+ run : |
567
+ echo "RUNVCPKG_NO_CACHE=1" >> $GITHUB_ENV
568
+ if : ${{ failure() || cancelled() }}
569
+ shell : bash
570
+
571
+
572
+ build_windows_cmake :
573
+ needs : changed
574
+ if : ${{ needs.changed.outputs.game_code == 'true' || needs.changed.outputs.unit_tests == 'true' || needs.changed.outputs.cmake_files == 'true' }}
575
+ runs-on : windows-latest
576
+ steps :
577
+ - uses : actions/checkout@v3
578
+ with :
579
+ submodules : true
580
+ - uses : lukka/get-cmake@latest
581
+ - uses : lukka/run-vcpkg@v10
582
+ with :
583
+ prependedCacheKey : mingw-x64
584
+ - uses : lukka/run-cmake@v10
585
+ with :
586
+ configurePreset : ' mingw-ci'
587
+ buildPreset : ' mingw-ci'
588
+ testPreset : ' mingw-ci'
589
+ - name : Run Benchmarks
590
+ run : ctest --preset mingw-ci-benchmark
591
+ - name : Prevent saving cache on failure
592
+ run : |
593
+ echo "RUNVCPKG_NO_CACHE=1" >> $GITHUB_ENV
594
+ if : ${{ failure() || cancelled() }}
595
+ shell : bash
596
+
597
+ build_macos_cmake :
598
+ needs : changed
599
+ if : ${{ needs.changed.outputs.game_code == 'true' || needs.changed.outputs.unit_tests == 'true' || needs.changed.outputs.cmake_files == 'true' }}
600
+ runs-on : macos-latest
601
+ steps :
602
+ - uses : actions/checkout@v3
603
+ with :
604
+ submodules : true
605
+ - uses : lukka/get-cmake@latest
606
+ - uses : lukka/run-vcpkg@v10
607
+ - uses : lukka/run-cmake@v10
608
+ with :
609
+ configurePreset : ' macos-ci'
610
+ buildPreset : ' macos-ci'
611
+ testPreset : ' macos-ci'
612
+ - name : Run Benchmarks
613
+ run : ctest --preset macos-ci-benchmark
614
+ - name : Prevent saving cache on failure
615
+ run : |
616
+ echo "RUNVCPKG_NO_CACHE=1" >> $GITHUB_ENV
617
+ if : ${{ failure() || cancelled() }}
618
+ shell : bash
619
+
620
+ build_windows_clang_cmake :
621
+ needs : changed
622
+ if : ${{ needs.changed.outputs.game_code == 'true' || needs.changed.outputs.unit_tests == 'true' || needs.changed.outputs.cmake_files == 'true' }}
623
+ runs-on : windows-latest
624
+ steps :
625
+ - uses : actions/checkout@v3
626
+ with :
627
+ submodules : true
628
+ - uses : lukka/get-cmake@latest
629
+ - uses : lukka/run-vcpkg@v10
630
+ with :
631
+ prependedCacheKey : vs-x64
632
+ - uses : lukka/run-cmake@v10
633
+ with :
634
+ configurePreset : ' clang-cl-ci'
635
+ buildPreset : ' clang-cl-ci'
636
+ testPreset : ' clang-cl-ci'
637
+ - name : Run Benchmarks
638
+ run : ctest --preset clang-cl-ci-benchmark
639
+ - name : Prevent saving cache on failure
640
+ run : |
641
+ echo "RUNVCPKG_NO_CACHE=1" >> $GITHUB_ENV
642
+ if : ${{ failure() || cancelled() }}
643
+ shell : bash
0 commit comments