From dbd5bb53b1e04072b0066ea091219e5cb019516e Mon Sep 17 00:00:00 2001 From: madeline Date: Mon, 2 Mar 2026 10:42:51 -0800 Subject: [PATCH] cherry pick platform variants --- .vscode/settings.json | 2 +- CMakeLists.txt | 2 +- cmake-variants.yaml | 27 +++++++++++++++++++++++++++ 3 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 cmake-variants.yaml diff --git a/.vscode/settings.json b/.vscode/settings.json index 1ee6a1c870..0af545d455 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,5 +1,5 @@ { - "cmake.buildDirectory": "${workspaceFolder}/build/dusk", + "cmake.buildDirectory": "${workspaceFolder}/build/dusk/${buildType}/${variant:platform}", "[c]": { "files.encoding": "utf8", "editor.defaultFormatter": "llvm-vs-code-extensions.vscode-clangd" diff --git a/CMakeLists.txt b/CMakeLists.txt index bdd458d5bb..6bcf65d88a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -65,7 +65,7 @@ target_include_directories(game_debug PUBLIC assets/${DUSK_TP_VERSION} libs/JSystem/include extern/aurora/include/dolphin - ${CMAKE_BINARY_DIR}/../${DUSK_TP_VERSION}/include + ${CMAKE_SOURCE_DIR}/build/${DUSK_TP_VERSION}/include build/${DUSK_TP_VERSION}/include) target_link_libraries(game_debug PUBLIC aurora::core aurora::gx aurora::si aurora::vi aurora::pad aurora::mtx aurora::os) diff --git a/cmake-variants.yaml b/cmake-variants.yaml new file mode 100644 index 0000000000..8307ce8420 --- /dev/null +++ b/cmake-variants.yaml @@ -0,0 +1,27 @@ +buildType: + default: Debug + choices: + debug: + short: Debug + long: Unoptimized with debug symbols + buildType: Debug + release: + short: Release + long: Optimized, no debug symbols + buildType: Release + +platform: + default: win64 + description: Target platform + choices: + win32: + short: Win32 + long: Windows 32-bit (MSVC) + settings: + CMAKE_GENERATOR_PLATFORM: Win32 + + win64: + short: Win64 + long: Windows 64-bit (MSVC) + settings: + CMAKE_GENERATOR_PLATFORM: x64