chore(ci): update CMake configuration for Linux and macOS builds

- Modified CI configuration to use the D-Bus portal for file dialogs on Linux for improved reliability.
- Updated CMake commands in both CI and release workflows to include the NFD_PORTAL option.
- Removed OpenSSL from vcpkg.json to streamline dependencies.

Benefits:
- Enhances build reliability across different platforms.
- Simplifies dependency management in the project.
This commit is contained in:
scawful
2025-10-13 10:29:47 -04:00
parent 58f3213c62
commit 6edfedff18
5 changed files with 29 additions and 13 deletions

View File

@@ -261,17 +261,31 @@ jobs:
run: |
set -e
echo "::group::CMake Configuration"
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=$BUILD_TYPE \
-DCMAKE_C_COMPILER=${{ matrix.cc }} \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DYAZE_BUILD_TESTS=ON \
-DYAZE_BUILD_EMU=OFF \
-DYAZE_ENABLE_ROM_TESTS=OFF 2>&1 | tee cmake_config.log
if [[ "${{ runner.os }}" == "Linux" ]]; then
# Linux: Use portal backend for file dialogs (more reliable in CI)
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=$BUILD_TYPE \
-DCMAKE_C_COMPILER=${{ matrix.cc }} \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DYAZE_BUILD_TESTS=ON \
-DYAZE_BUILD_EMU=OFF \
-DYAZE_ENABLE_ROM_TESTS=OFF \
-DNFD_PORTAL=ON 2>&1 | tee cmake_config.log
else
# macOS: Use default GTK backend
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=$BUILD_TYPE \
-DCMAKE_C_COMPILER=${{ matrix.cc }} \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DYAZE_BUILD_TESTS=ON \
-DYAZE_BUILD_EMU=OFF \
-DYAZE_ENABLE_ROM_TESTS=OFF 2>&1 | tee cmake_config.log
fi
echo "::endgroup::"
# Note: Full-featured build to match release configuration
# Note: YAZE_BUILD_EMU=OFF disables standalone emulator executable
# but yaze_emulator library is still built for main app/tests
# Note: NFD_PORTAL=ON uses D-Bus portal instead of GTK on Linux (more reliable in CI)
- name: Report Configure Failure
if: failure() && (steps.configure_windows.outcome == 'failure' || steps.configure_unix.outcome == 'failure')

View File

@@ -287,11 +287,13 @@ jobs:
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} \
-DYAZE_BUILD_EMU=OFF \
-DYAZE_BUILD_TESTS=ON \
-DYAZE_ENABLE_ROM_TESTS=OFF 2>&1 | tee cmake_config.log
-DYAZE_ENABLE_ROM_TESTS=OFF \
-DNFD_PORTAL=ON 2>&1 | tee cmake_config.log
echo "::endgroup::"
# Note: YAZE_BUILD_EMU=OFF disables standalone emulator executable
# but yaze_emulator library is still built for main app
# Note: Tests enabled for pre-1.0 releases to catch issues before publishing
# Note: NFD_PORTAL=ON uses D-Bus portal instead of GTK for file dialogs (more reliable in CI)
- name: "Report Configure Failure"
if: |

View File

@@ -75,6 +75,7 @@ message(STATUS " - GFX Tier: gfx_backend configured")
set(GFX_RESOURCE_SRC
app/gfx/resource/arena.cc
app/gfx/resource/memory_pool.cc
app/gfx/render/background_buffer.cc
)
add_library(yaze_gfx_resource STATIC ${GFX_RESOURCE_SRC})
configure_gfx_library(yaze_gfx_resource)
@@ -122,7 +123,6 @@ set(GFX_RENDER_SRC
app/gfx/render/atlas_renderer.cc
app/gfx/render/texture_atlas.cc
app/gfx/render/tilemap.cc
app/gfx/render/background_buffer.cc
)
add_library(yaze_gfx_render STATIC ${GFX_RENDER_SRC})
configure_gfx_library(yaze_gfx_render)

View File

@@ -47,6 +47,10 @@ if(YAZE_BUILD_TESTS)
message(STATUS "Configuring Windows stack size for ${suite_name} to 16MB")
if(MSVC)
target_link_options(${suite_name} PRIVATE /STACK:16777216)
# Force whole-archive linking for protobuf to ensure all symbols are included
if(YAZE_WITH_GRPC)
target_link_options(${suite_name} PRIVATE /WHOLEARCHIVE:libprotobuf)
endif()
else()
target_link_options(${suite_name} PRIVATE -Wl,--stack,16777216)
endif()

View File

@@ -18,10 +18,6 @@
{
"name": "zlib",
"platform": "windows"
},
{
"name": "openssl",
"platform": "windows"
}
],
"overrides": [