mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-07-09 02:39:42 +00:00
2919e1899fff80106084e8ba10264733c546ba0d
Query the natively compiled-in subsystems at runtime so the Java side only registers and initializes the managers that exist, fixing UnsatisfiedLinkError when SDL is built with a subsystem disabled (e.g. -DSDL_AUDIO_DISABLED). - Add SDL.setupJNI(int subsystems) plus SDL_INIT_* Java constants; SDLActivity passes an overridable getInitSubsystems() mask so custom activities can skip Java-side setup for unused subsystems. - Distinguish compiled from requested subsystems: JNI registration follows nativeGetCompiledSubsystems(), while manager initialization and surface/layout creation follow the requested-and-compiled mask. - Gate HIDDeviceManager.acquire() (USB/BLE device scanning) on a new nativeIsHIDAPIEnabled() query so HIDAPI-less builds never touch it. - Gate SDLControllerManager.initializeDeviceListener() and the joystick key-event path on the controller subsystem; gate the clipboard handler on video, mirroring the native guards. - Guard the SDLControllerManager JNI bindings with SDL_ANDROID_NEED_CONTROLLER_MANAGER (joystick or haptic enabled). - Skip layout updates in ShowTextInputTask when no layout exists (video disabled). - Reorganize SDL_android.h/.c into guarded per-subsystem groups with matching ordering.
Simple DirectMedia Layer (SDL for short) is a cross-platform library designed to make it easy to write multi-media software, such as games and emulators.
You can find the latest release and additional information at: https://www.libsdl.org/
Installation instructions and a quick introduction is available in INSTALL.md
This library is distributed under the terms of the zlib license, available in LICENSE.txt.
Enjoy!
Sam Lantinga (slouken@libsdl.org)
Languages
C
87.9%
C++
4%
Objective-C
3.4%
CMake
1.7%
Java
0.8%
Other
1.9%