Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/move pipeline settings to preset #711

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 8 additions & 20 deletions .github/workflows/build-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,19 @@ jobs:
- macos-11
include:
- os: windows-2022
cmake_options: -DWITH_DRIVER_DIRECT3D=ON -DWITH_DRIVER_XAUDIO2=ON
cmake_preset: windows-client
- os: windows-2019
cmake_options: -DWITH_DRIVER_DIRECT3D=ON -DWITH_DRIVER_XAUDIO2=ON
cmake_preset: windows-client
- os: ubuntu-22.04
ubuntu_version: 22.04
cmake_preset: linux-client
- os: ubuntu-20.04
ubuntu_version: 20.04
cmake_preset: linux-client
- os: macos-14
cmake_options: -DWITH_LIBXML2_ICONV=OFF -GXcode
cmake_preset: macos-client
- os: macos-11
cmake_options: -DWITH_LIBXML2_ICONV=OFF -GXcode
cmake_preset: macos-client

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -98,25 +100,11 @@ jobs:

- name: Configure CMake
run: >
cmake --version;
cmake -B ${{ steps.strings.outputs.build-output-dir }}
${{ matrix.cmake_options }}
-DCMAKE_CONFIGURATION_TYPES=Release
-DFINAL_VERSION=OFF
cmake --preset ${{ matrix.cmake_preset }}
-DHUNTER_CONFIGURATION_TYPES=Release
-DHUNTER_ENABLED=ON
-DHUNTER_ROOT=${{ steps.strings.outputs.hunter-dir }}
-DWITH_DRIVER_OPENAL=ON
-DWITH_DRIVER_OPENGL=ON
-DWITH_INSTALL_LIBRARIES=OFF
-DWITH_NEL_SAMPLES=OFF
-DWITH_NEL_TESTS=OFF
-DWITH_NEL_TOOLS=OFF
-DWITH_RYZOM_CLIENT=ON
-DWITH_RYZOM_SERVER=OFF
-DWITH_RYZOM_TOOLS=OFF
-S ${{ github.workspace }}

- name: Build
# Build your program with the given configuration. Note that --config is needed because the default Windows generator is a multi-config generator (Visual Studio generator).
run: cmake --build ${{ steps.strings.outputs.build-output-dir }} --config Release
run: cmake --build --preset client
83 changes: 79 additions & 4 deletions CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,39 @@
{
"name": "base",
"hidden": true,
"generator": "Ninja Multi-Config",
"binaryDir": "${sourceDir}/build"
},
{
"inherits": [
"base"
],
"name": "linux",
"inherits": "base",
"generator": "Ninja Multi-Config",
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Linux"
}
},
{
"name": "windows",
"inherits": "base",
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
}
},
{
"name": "macos",
"inherits": "base",
"generator": "Xcode",
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Darwin"
}
},
{
"inherits": "base",
"name": "default",
"cacheVariables": {
"WITH_STATIC": true,
Expand Down Expand Up @@ -41,6 +67,50 @@
"CMAKE_C_FLAGS": "--coverage",
"CMAKE_CXX_FLAGS": "--coverage"
}
},
{
"inherits": "base",
"name": "client",
"cacheVariables": {
"FINAL_VERSION": false,
"WITH_DRIVER_OPENAL": true,
"WITH_DRIVER_OPENGL": true,
"WITH_INSTALL_LIBRARIES": false,
"WITH_NEL_SAMPLES": false,
"WITH_NEL_TESTS": false,
"WITH_NEL_TOOLS": false,
"WITH_RYZOM_CLIENT": true,
"WITH_RYZOM_SERVER": false,
"WITH_RYZOM_TOOLS": false
}
},
{
"inherits": [
"linux",
"client"
],
"name": "linux-client"
},
{
"inherits": [
"windows",
"client"
],
"name": "windows-client",
"cacheVariables": {
"WITH_DRIVER_DIRECT3D": true,
"WITH_DRIVER_XAUDIO2": true
}
},
{
"inherits": [
"macos",
"client"
],
"name": "macos-client",
"cacheVariables": {
"WITH_LIBXML2_ICONV": false
}
}
],
"buildPresets": [
Expand All @@ -53,6 +123,11 @@
"name": "release",
"configurePreset": "default",
"configuration": "Release"
},
{
"name": "client",
"configurePreset": "client",
"configuration": "Release"
}
],
"testPresets": [
Expand Down
Loading