Skip to content

Commit

Permalink
Cleanup github build workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
mikke89 committed Apr 1, 2024
1 parent e9483a0 commit 5eab010
Showing 1 changed file with 31 additions and 51 deletions.
82 changes: 31 additions & 51 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,47 @@ on: [push, pull_request]

jobs:
Linux:
runs-on: ubuntu-latest

env:
BUILD_TYPE: Release
CC: ${{ matrix.cc }}
CXX: ${{ matrix.cxx }}

strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
build_type: [Release]
include:
- cc: clang
cxx: clang++
cmake_options: -DRMLUI_BACKEND=GLFW_GL2 -DRMLUI_PRECOMPILED_HEADERS=OFF
- cc: clang
cxx: clang++
cmake_options: -DRMLUI_BACKEND=SDL_VK -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Debug
- cmake_options: -DRMLUI_BACKEND=GLFW_GL3 -DBUILD_TESTING=ON -DRMLUI_PRECOMPILED_HEADERS=OFF
build_type: Debug
cmake_options: -DRMLUI_BACKEND=SDL_VK -DBUILD_TESTING=ON
- cmake_options: -DRMLUI_BACKEND=GLFW_GL3 -DBUILD_TESTING=ON
enable_testing: true
- cmake_options: -DRMLUI_BACKEND=X11_GL2 -DRMLUI_LOTTIE_PLUGIN=ON
- cmake_options: -DRMLUI_BACKEND=SDL_GL2 -DRMLUI_CUSTOM_RTTI=ON -DCMAKE_CXX_FLAGS="-fno-exceptions -fno-rtti"
- cmake_options: -DRMLUI_BACKEND=SFML_GL2 -DRMLUI_THIRDPARTY_CONTAINERS=OFF
- cmake_options: -DRMLUI_BACKEND=GLFW_VK -DRMLUI_VK_DEBUG=ON -DRMLUI_PRECOMPILED_HEADERS=OFF -DCMAKE_BUILD_TYPE=Debug
- build_type: Debug
cmake_options: -DRMLUI_BACKEND=GLFW_VK -DRMLUI_VK_DEBUG=ON -DRMLUI_PRECOMPILED_HEADERS=OFF
- os: ubuntu-20.04
cc: clang
cxx: clang++
build_type: Debug
cmake_options: -DRMLUI_BACKEND=GLFW_GL2
- os: ubuntu-20.04
cc: clang
cxx: clang++
cmake_options: -DRMLUI_BACKEND=SDL_VK -DBUILD_TESTING=ON -DRMLUI_PRECOMPILED_HEADERS=OFF
- os: ubuntu-20.04
cmake_options: -DBUILD_TESTING=ON
- os: ubuntu-20.04
build_type: Debug
cmake_options: -DRMLUI_BACKEND=native -DRMLUI_VK_DEBUG=ON

runs-on: ${{ matrix.os }}

env:
BUILD_TYPE: ${{ matrix.build_type }}
CC: ${{ matrix.cc }}
CXX: ${{ matrix.cxx }}

steps:
- uses: actions/checkout@v4
Expand All @@ -50,44 +68,6 @@ jobs:
run: ctest


Linux-legacy:
runs-on: ubuntu-20.04

env:
BUILD_TYPE: Release
CC: ${{ matrix.cc }}
CXX: ${{ matrix.cxx }}

strategy:
fail-fast: false
matrix:
include:
- cc: clang
cxx: clang++
cmake_options: -DRMLUI_PRECOMPILED_HEADERS=OFF -DRMLUI_BACKEND=GLFW_GL2
- cc: clang
cxx: clang++
cmake_options: -DRMLUI_BACKEND=SDL_VK -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Debug
- cmake_options: -DBUILD_TESTING=ON
- cmake_options: -DRMLUI_BACKEND=GLFW_VK -DRMLUI_VK_DEBUG=ON -DRMLUI_PRECOMPILED_HEADERS=OFF -DCMAKE_BUILD_TYPE=Debug

steps:
- uses: actions/checkout@v4

- name: Install Dependencies
run: |-
sudo apt-get update
sudo apt-get install cmake ninja-build libsdl2-dev libsdl2-image-dev libfreetype6-dev libharfbuzz-dev libglew-dev liblua5.2-dev libglfw3-dev
- name: Configure CMake
run: >-
cmake -B Build -G Ninja --preset samples-all -DRMLUI_SVG_PLUGIN=OFF -DRMLUI_LOTTIE_PLUGIN=OFF -Wdev -Werror=dev -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DRMLUI_WARNINGS_AS_ERRORS=ON
${{ matrix.cmake_options }}
- name: Build
run: cmake --build Build


macOS:
runs-on: macos-latest

Expand All @@ -109,13 +89,13 @@ jobs:

- name: Configure CMake
run: >-
cmake -B Build --preset samples -Wdev -Werror=dev -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DRMLUI_WARNINGS_AS_ERRORS=ON
cmake -B Build --preset samples -Wdev -Werror=dev -DRMLUI_WARNINGS_AS_ERRORS=ON
-DCMAKE_CXX_FLAGS="-DGL_SILENCE_DEPRECATION"
-DRMLUI_LUA_BINDINGS=ON
${{ matrix.cmake_options }}
- name: Build
run: cmake --build Build --config $BUILD_TYPE
run: cmake --build Build


Windows:
Expand All @@ -141,7 +121,7 @@ jobs:

- name: Configure CMake
run: >-
cmake -B Build --preset samples -Wdev -Werror=dev -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=$env:BUILD_TYPE
cmake -B Build --preset samples -Wdev -Werror=dev -DBUILD_SHARED_LIBS=ON
-DRMLUI_LUA_BINDINGS=ON -DRMLUI_WARNINGS_AS_ERRORS=ON
-DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake" ${{ matrix.cmake_options }}
Expand Down

0 comments on commit 5eab010

Please sign in to comment.