Skip to content

Commit

Permalink
Try to update SDL to 2.26.0
Browse files Browse the repository at this point in the history
  • Loading branch information
o01eg committed Dec 22, 2024
1 parent d32d6a1 commit e863616
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions Sources.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ set(FREETYPE_VERSION 2.9)
set(FREETYPE_URL http://downloads.sourceforge.net/project/freetype/freetype2/${FREETYPE_VERSION}/freetype-${FREETYPE_VERSION}.tar.gz)
set(FREETYPE_MD5 d23a1b246e78890458c6672cb45eacd0)

set(SDL_VERSION 2.24.2)
set(SDL_VERSION 2.26.0)
set(SDL_URL https://www.libsdl.org/release/SDL2-${SDL_VERSION}.tar.gz)
set(SDL_MD5 84c71cb2a14aa0d9504513c0b9fcb17c)
set(SDL_MD5 35bc58cfe41b8fb6c8e6646be26fa47e)

set(LIBOGG_VERSION 1.3.2)
set(LIBOGG_URL http://downloads.xiph.org/releases/ogg/libogg-${LIBOGG_VERSION}.tar.gz)
Expand Down
20 changes: 10 additions & 10 deletions patches/sdl/0004-CMake-Add-MacOSX-Framework-support.patch
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,20 @@ Subject: [PATCH] CMake: Add MacOSX Framework support
1 file changed, 13 insertions(+)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 707eb5c..af93a52 100644
index a596eec..7f6e574 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -505,6 +505,9 @@ dep_option(SDL_HIDAPI_LIBUSB "Use libusb for low level joystick drivers" O
dep_option(SDL_HIDAPI_JOYSTICK "Use HIDAPI for low level joystick drivers" ON SDL_HIDAPI OFF)
dep_option(SDL_VIRTUAL_JOYSTICK "Enable the virtual-joystick driver" ON SDL_HIDAPI OFF)
@@ -514,6 +514,9 @@ dep_option(SDL_VIRTUAL_JOYSTICK "Enable the virtual-joystick driver" ON SDL_H
set_option(SDL_ASAN "Use AddressSanitizer to detect memory errors" OFF)
option_string(SDL_VENDOR_INFO "Vendor name and/or version to add to SDL_REVISION" "")
set_option(SDL_CCACHE "Use Ccache to speed up build" ON)
+if(APPLE)
+ set_option(BUILD_FRAMEWORK "Build Framework bundle for OSX" OFF)
+endif()

option(SDL_SHARED "Build a shared version of the library" ${SDL_SHARED_ENABLED_BY_DEFAULT})
option(SDL_STATIC "Build a static version of the library" ${SDL_STATIC_ENABLED_BY_DEFAULT})
@@ -3097,6 +3100,16 @@ if(SDL_SHARED)
option(SDL_WERROR "Enable -Werror" OFF)

@@ -3320,6 +3323,16 @@ if(SDL_SHARED)
endif()
set_target_properties(SDL2 PROPERTIES STATIC_LIBRARY_FLAGS "/NODEFAULTLIB")
endif()
Expand All @@ -38,10 +38,10 @@ index 707eb5c..af93a52 100644
# FIXME: if CMAKE_VERSION >= 3.13, use target_link_options for EXTRA_LDFLAGS
target_link_libraries(SDL2 PRIVATE ${EXTRA_LIBS} ${EXTRA_LDFLAGS} ${EXTRA_LDFLAGS_BUILD})
target_include_directories(SDL2 PUBLIC
@@ -3288,7 +3301,7 @@ if(NOT SDL2_DISABLE_INSTALL)
set(SOPOSTFIX "")
@@ -3518,7 +3531,7 @@ if(NOT SDL2_DISABLE_INSTALL)
install(FILES ${SDL2_BINARY_DIR}/sdl2.pc
DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
endif()

- if(NOT (WINDOWS OR CYGWIN) OR MINGW)
+ if((NOT (WINDOWS OR CYGWIN) OR MINGW) AND (NOT BUILD_FRAMEWORK))
if(SDL_SHARED)
Expand Down

0 comments on commit e863616

Please sign in to comment.