Skip to content

meson: Bump SDL3 to 3.4.2#2751

Merged
mborgerson merged 1 commit intoxemu-project:masterfrom
mborgerson:sync/sdl-3.4.2
Feb 26, 2026
Merged

meson: Bump SDL3 to 3.4.2#2751
mborgerson merged 1 commit intoxemu-project:masterfrom
mborgerson:sync/sdl-3.4.2

Conversation

@mborgerson
Copy link
Member

@mborgerson mborgerson commented Feb 21, 2026

@gemini-code-assist
Copy link

Summary of Changes

Hello @mborgerson, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request updates the project's dependency on the SDL3 library to version 3.4.2. The change primarily involves updating the Meson wrap file to point to the new SDL3 release and incorporating its comprehensive Meson build configurations. This ensures the project leverages the most current version of SDL3, benefiting from its latest advancements and maintaining a robust build setup.

Highlights

  • SDL3 Version Bump: The SDL3 library has been upgraded to version 3.4.2, bringing the latest features, bug fixes, and improvements.
  • Meson Build System Integration: The project now integrates the native Meson build files for SDL3 3.4.2, streamlining its compilation process and dependency management.
  • Dependency Management Update: The sdl3.wrap file was updated to fetch the new SDL3 source directly, removing previous patch-based handling for this dependency.
Changelog
  • subprojects/packagefiles/SDL3-3.4.2/LICENSE.build
    • Added the Meson development team's license for the SDL3 build files
  • subprojects/packagefiles/SDL3-3.4.2/meson.build
    • Added the main Meson build definition for SDL3 3.4.2
    • Configured platform-specific features, dependencies, and compilation flags for Windows, Linux, and macOS
  • subprojects/packagefiles/SDL3-3.4.2/src//*.build**
    • Added numerous Meson build files across various SDL3 source subdirectories
    • Defined the compilation of specific source files for each SDL3 module and platform
  • subprojects/packagefiles/SDL3-3.4.2/wayland-protocols/meson.build
    • Added Wayland protocol XML files
    • Configured generation of Wayland client protocol headers and sources
  • subprojects/sdl3.wrap
    • Updated SDL3 version from 3.4.0 to 3.4.2
    • Modified source URL and hash to reflect the new version
    • Adjusted patch handling by removing specific patch files and adding a patch directory
Activity
  • No specific activity (comments, reviews, progress) has been recorded for this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

The pull request successfully bumps SDL3 to version 3.4.2 and transitions from using a WrapDB patch to local package files. The build system logic has been updated to reflect the new version and structure. I have identified a few minor issues related to typo in variable names, misplaced function checks in header lists, and potential inconsistencies in platform detection logic.

['ddraw.h', 'HAVE_DDRAW_H'],
['dsound.h', 'HAVE_DSOUND_H'],
['dinput.h', 'HAVE_DINPUT_H'],
['signal.h', 'HAVE_SIGTIMEDWAIT'],

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The entry ['signal.h', 'HAVE_SIGTIMEDWAIT'] is misplaced in the basic_headers list. sigtimedwait is a function, not a header file. It should be moved to the check_functions list, and signal.h is already checked on line 57.

Comment on lines +310 to +315
sdl_deps += dependency('libudev')
sdl_deps += dependency('dbus-1')
sdl_deps += dependency('libpipewire-0.3')
sdl_deps += dependency('wayland-client')
sdl_deps += dependency('wayland-egl')
sdl_deps += dependency('wayland-cursor')

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

These dependencies (udev, dbus, pipewire, wayland-*) are added to sdl_deps without required: false. This will cause the build to fail on Linux systems where these libraries are missing. In SDL, these are typically optional features.

  sdl_deps += dependency('libudev', required: false)
  sdl_deps += dependency('dbus-1', required: false)
  sdl_deps += dependency('libpipewire-0.3', required: false)
  sdl_deps += dependency('wayland-client', required: false)
  sdl_deps += dependency('wayland-egl', required: false)
  sdl_deps += dependency('wayland-cursor', required: false)

sdl_deps += cc.find_library('setupapi')
sdl_deps += cc.find_library('winmm')
sdl_deps += cc.find_library('opengl32')
elif host_machine.subsystem() == 'macos'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Using host_machine.subsystem() == 'macos' is inconsistent with the check on line 235 which uses host_machine.system() == 'darwin'. It is generally safer and more standard in Meson to use host_machine.system() == 'darwin' for macOS detection.

elif host_machine.system() == 'darwin'

)

# parse XKB version to avoid issues within SDL3 config
xkdbcommon_version = xkbcommon_dep.version().split('.')

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

There is a typo in the variable name xkdbcommon_version. It should likely be xkbcommon_version to match the dependency name xkbcommon_dep.

xkbcommon_version = xkbcommon_dep.version().split('.')

Comment on lines +20 to +22
xkdbcommon_major = xkdbcommon_version[0].to_int()
xkdbcommon_minor = xkdbcommon_version[1].to_int()
xkdbcommon_patch = xkdbcommon_version[2].to_int()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

These variable names also contain the typo 'xkdb'.

xkbcommon_major = xkbcommon_version[0].to_int()
xkbcommon_minor = xkbcommon_version[1].to_int()
xkbcommon_patch = xkbcommon_version[2].to_int()

Comment on lines +24 to +26
cdata.set('SDL_XKBCOMMON_VERSION_MAJOR', xkdbcommon_major)
cdata.set('SDL_XKBCOMMON_VERSION_MINOR', xkdbcommon_minor)
cdata.set('SDL_XKBCOMMON_VERSION_PATCH', xkdbcommon_patch)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Updating the cdata.set calls to use the corrected variable names.

cdata.set('SDL_XKBCOMMON_VERSION_MAJOR', xkbcommon_major)
cdata.set('SDL_XKBCOMMON_VERSION_MINOR', xkbcommon_minor)
cdata.set('SDL_XKBCOMMON_VERSION_PATCH', xkbcommon_patch)

@Bobble80
Copy link

Just did a quick test and the over brightened lighting issue in Xemu seems to be fixed in that new SDL update.

@mborgerson mborgerson marked this pull request as ready for review February 26, 2026 00:16
@mborgerson
Copy link
Member Author

Not gonna wait for wrapdb. We'll handle it independently for now.

@mborgerson mborgerson merged commit fc9980d into xemu-project:master Feb 26, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants