0
0
mirror of https://github.com/termux/termux-packages.git synced 2025-05-31 15:12:07 +00:00
Files
termux-packages/x11-packages/luanti/0003-fix-incompatible-type-ekey-code.patch
Robert Kirkman dbfe81691b bump(x11/luanti): 5.12.0
- Fixes https://github.com/termux/termux-packages/issues/24817

- Luanti upstream officially migrated to SDL2, but if this build in Termux is switched to SDL2, some problems would happen:
  - EGL support would be disabled, which would significantly reduce performance and driver compatibility
  - A bug would start happening where the colors of everything would look strangely washed out
- Therefore, because non-SDL2 mode is still working well in this release, it makes more sense to keep `-DUSE_SDL2=0` for now, until the above problems are solved separately.

- `0001-fix-elf-directory-for-cross-compiling.patch` is no longer necessary, because the original problem was an error that happened because of `EXECUTABLE_OUTPUT_PATH` not being set during cross-compilation, now after 0695541bf5, `EXECUTABLE_OUTPUT_PATH` is always set to something that works in both `TERMUX_ON_DEVICE_BUILD=false` mode and `TERMUX_ON_DEVICE_BUILD=true` mode, so the patch is not necessary anymore.
2025-05-25 14:39:34 -05:00

14 lines
629 B
Diff

This prevents an error during compiling with recent C++ compilers while SDL2 is disabled,
which was: CIrrDeviceLinux.cpp:682:13: error: assigning to 'EKEY_CODE' from incompatible type 'int'
--- a/irr/src/CIrrDeviceLinux.cpp
+++ b/irr/src/CIrrDeviceLinux.cpp
@@ -693,7 +693,7 @@ EKEY_CODE CIrrDeviceLinux::getKeyCode(XEvent &event)
keyCode = (EKEY_CODE)KeyMap[idx].Win32Key;
}
if (keyCode == 0) {
- keyCode = KEY_UNKNOWN;
+ keyCode = (EKEY_CODE)KEY_UNKNOWN;
if (!mp.X11Key) {
os::Printer::log("No such X11Key, event keycode", core::stringc(event.xkey.keycode).c_str(), ELL_INFORMATION);
} else if (idx == -1) {