From df439aede26b10c41419132b798f644b1e15f895 Mon Sep 17 00:00:00 2001 From: Gamer64 <76565986+Gamer64ytb@users.noreply.github.com> Date: Tue, 10 Sep 2024 00:08:30 +0200 Subject: [PATCH] externals: update SDL --- CMakeLists.txt | 7 ++++++- externals/CMakeLists.txt | 3 +++ externals/cubeb | 2 +- externals/sdl2/SDL | 2 +- src/core/core.cpp | 4 ++-- 5 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index af026a4e40..9fc0b2de51 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -8,9 +8,14 @@ cmake_policy(SET CMP0069 NEW) # Honor visibility properties for all targets # Set the default so subdirectory cmake_minimum_required calls won't unset the policy. cmake_policy(SET CMP0063 NEW) +set(CMAKE_POLICY_DEFAULT_CMP0063 NEW) +# Needed to compile sdl2 2.30.5+ on MSVC +set(CMAKE_POLICY_DEFAULT_CMP0077 NEW) +# Allow use with targets in other directories +cmake_policy(SET CMP0079 NEW) +set(CMAKE_POLICY_DEFAULT_CMP0079 NEW) # Allow conditions to be used in cmake_dependent_option cmake_policy(SET CMP0127 NEW) -set(CMAKE_POLICY_DEFAULT_CMP0063 NEW) list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules") list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/externals/cmake-modules") diff --git a/externals/CMakeLists.txt b/externals/CMakeLists.txt index 205c63c8e5..8762702b2f 100644 --- a/externals/CMakeLists.txt +++ b/externals/CMakeLists.txt @@ -186,6 +186,9 @@ add_subdirectory(teakra EXCLUDE_FROM_ALL) # SDL2 if (ENABLE_SDL2 AND NOT USE_SYSTEM_SDL2) + if (MSVC) + set (SDL_LIBC ON) + endif() add_subdirectory(sdl2) endif() diff --git a/externals/cubeb b/externals/cubeb index 799e775484..19d2f7bce6 160000 --- a/externals/cubeb +++ b/externals/cubeb @@ -1 +1 @@ -Subproject commit 799e775484b8fce7e986ee7a4f4b651fec2bca07 +Subproject commit 19d2f7bce6a4d0566a07f3187d2bc5f0ec95c1c4 diff --git a/externals/sdl2/SDL b/externals/sdl2/SDL index ac13ca9ab6..54757c29dd 160000 --- a/externals/sdl2/SDL +++ b/externals/sdl2/SDL @@ -1 +1 @@ -Subproject commit ac13ca9ab691e13e8eebe9684740ddcb0d716203 +Subproject commit 54757c29dd4e8783d57e6b0d2261bd00f66c3f0d diff --git a/src/core/core.cpp b/src/core/core.cpp index 437eeca8da..219f64c6dd 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -262,7 +262,7 @@ static void LoadOverrides(u64 title_id) { } // Fully tested games that runs better and without issues with this tweak. - const std::array force_hw_vertex_shaders_ids = { + const std::array force_hw_vs_ids = { 0x0004000000068B00, // Tales of the Abyss / Pac Man Party 3D 0x0004000000061300, // Tales of the Abyss / Pac Man Party 3D 0x000400000004A700, // Tales of the Abyss / Pac Man Party 3D @@ -272,7 +272,7 @@ static void LoadOverrides(u64 title_id) { 0x000400000016AD00, // Dragon Quest Monsters Joker 3 0x00040000001ACB00 // Dragon Quest Monsters Joker 3 Professional }; - for (auto id : force_hw_vertex_shaders_ids) { + for (auto id : force_hw_vs_ids) { if (title_id == id) { Settings::values.force_hw_vertex_shaders = true; break;