From 915625b74f0b241229187ab05d716ed592cf2873 Mon Sep 17 00:00:00 2001 From: Jan Date: Wed, 20 Apr 2022 22:30:41 +0200 Subject: [PATCH] Update SDL to 2.0.20 (#884) --- meson.build | 32 +++++++++++++++++++++++++++++++- subprojects/sdl2.wrap | 14 +++++++------- 2 files changed, 38 insertions(+), 8 deletions(-) diff --git a/meson.build b/meson.build index 9dbe9bec..0e5c62ac 100644 --- a/meson.build +++ b/meson.build @@ -99,8 +99,38 @@ if not get_option('source-only') default_options: default_fallback_options + ['default_library=static', 'zlib=disabled', 'bzip2=disabled', 'png=disabled', 'harfbuzz=disabled', 'brotli=disabled'] ) + + sdl_options = ['default_library=static'] + + # we explicitly need these + sdl_options += 'use_loadso=enabled' + sdl_options += 'prefer_dlopen=true' + sdl_options += 'use_video=enabled' + sdl_options += 'use_atomic=enabled' + sdl_options += 'use_threads=enabled' + # investigate if this is truly needed + # Do not remove before https://github.com/libsdl-org/SDL/issues/5413 is released + sdl_options += 'use_events=enabled' + + # we leave this up to what the host system has + sdl_options += 'use_video_x11=auto' + sdl_options += 'use_video_wayland=auto' + + # we don't need these + sdl_options += 'use_timers=disabled' + sdl_options += 'use_sensor=disabled' + sdl_options += 'use_haptic=disabled' + sdl_options += 'use_audio=disabled' + sdl_options += 'use_cpuinfo=disabled' + sdl_options += 'use_joystick=disabled' + sdl_options += 'use_video_opengl=disabled' + sdl_options += 'use_video_openglesv2=disabled' + sdl_options += 'use_video_vulkan=disabled' + sdl_options += 'use_video_offscreen=disabled' + sdl_options += 'use_power=disabled' + sdl_dep = dependency('sdl2', fallback: ['sdl2', 'sdl2_dep'], - default_options: default_fallback_options + ['default_library=static'] + default_options: default_fallback_options + sdl_options ) lite_deps = [lua_dep, sdl_dep, freetype_dep, pcre2_dep, libm, libdl] diff --git a/subprojects/sdl2.wrap b/subprojects/sdl2.wrap index 9ef9e1d3..b1affeb5 100644 --- a/subprojects/sdl2.wrap +++ b/subprojects/sdl2.wrap @@ -1,11 +1,11 @@ [wrap-file] -directory = SDL2-2.0.18 -source_url = https://www.libsdl.org/release/SDL2-2.0.18.tar.gz -source_filename = SDL2-2.0.18.tar.gz -source_hash = 94d40cd73dbfa10bb6eadfbc28f355992bb2d6ef6761ad9d4074eff95ee5711c -patch_filename = sdl2_2.0.18-2_patch.zip -patch_url = https://wrapdb.mesonbuild.com/v2/sdl2_2.0.18-2/get_patch -patch_hash = cd77f33395d3d019bb89217b9da41fc640ed8c78cbbbebc5c662155a25e2820e +directory = SDL2-2.0.20 +source_url = https://libsdl.org/release/SDL2-2.0.20.tar.gz +source_filename = SDL2-2.0.20.tar.gz +source_hash = c56aba1d7b5b0e7e999e4a7698c70b63a3394ff9704b5f6e1c57e0c16f04dd06 +patch_filename = sdl2_2.0.20-3_patch.zip +patch_url = https://wrapdb.mesonbuild.com/v2/sdl2_2.0.20-3/get_patch +patch_hash = ade644ba46cefa4f1f9e57aa23bacc5dabf762d1f90d8416a1e1e4b0b7a188c4 [provide] sdl2 = sdl2_dep