From cdd603b3b3345a02357c4a1bd6376de43c79cd47 Mon Sep 17 00:00:00 2001 From: Jools Wills Date: Sat, 9 Apr 2016 22:07:12 +0100 Subject: [PATCH 1/2] Revert "Linux joystick: Look at entire axis namespace for controls (thanks, "spaz16"!)." This reverts commit 4cb7923f251543c1175c1702f8cf8b4201ce9054. see https://github.com/RetroPie/RetroPie-Setup/issues/1297 --- src/joystick/linux/SDL_sysjoystick.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/joystick/linux/SDL_sysjoystick.c b/src/joystick/linux/SDL_sysjoystick.c index 84d99a2c2..ee855b895 100644 --- a/src/joystick/linux/SDL_sysjoystick.c +++ b/src/joystick/linux/SDL_sysjoystick.c @@ -649,7 +649,7 @@ ConfigJoystick(SDL_Joystick * joystick, int fd) ++joystick->nbuttons; } } - for (i = 0; i < ABS_MAX; ++i) { + for (i = 0; i < ABS_MISC; ++i) { /* Skip hats */ if (i == ABS_HAT0X) { i = ABS_HAT3Y; @@ -913,6 +913,10 @@ HandleInputEvents(SDL_Joystick * joystick) events[i].value); break; case EV_ABS: + if (code >= ABS_MISC) { + break; + } + switch (code) { case ABS_HAT0X: case ABS_HAT0Y: From 45a675e6fab781653155d1cc94d68b597df5ad91 Mon Sep 17 00:00:00 2001 From: Jools Wills Date: Fri, 17 Feb 2017 17:16:05 +0000 Subject: [PATCH 2/2] packaging fixes - * updated debian/control to match debian/ubuntu package names * fix libudev dependency * added additional mesa dependencies * rename libsdl2.install -> libsdl2-2.0-0.install --- debian/control | 15 +++++++++------ debian/{libsdl2.install => libsdl2-2.0-0.install} | 0 2 files changed, 9 insertions(+), 6 deletions(-) rename debian/{libsdl2.install => libsdl2-2.0-0.install} (100%) diff --git a/debian/control b/debian/control index a3411335a..ac45d5a8f 100644 --- a/debian/control +++ b/debian/control @@ -13,7 +13,10 @@ Build-Depends: debhelper (>= 9), dpkg-dev (>= 1.16.1~), fcitx-libs-dev [linux-any], libasound2-dev [linux-any], + libegl1-mesa-dev, libgl1-mesa-dev, + libgles2-mesa-dev, + libglu1-mesa-dev, libpulse-dev, libudev-dev [linux-any], libdbus-1-dev [linux-any], @@ -30,16 +33,16 @@ Build-Depends: debhelper (>= 9), libxxf86vm-dev Homepage: http://www.libsdl.org/ -Package: libsdl2 +Package: libsdl2-2.0-0 Architecture: any Multi-Arch: same Pre-Depends: ${misc:Pre-Depends} Depends: ${misc:Depends}, ${shlibs:Depends}, - libudev0 [linux-any], + libudev0 | libudev1 [linux-any], libdbus-1-3 [linux-any] -Conflicts: libsdl-1.3-0 -Replaces: libsdl-1.3-0 +Conflicts: libsdl-1.3-0, libsdl2 +Replaces: libsdl-1.3-0, libsdl2 Description: Simple DirectMedia Layer SDL is a library that allows programs portable low level access to a video framebuffer, audio output, mouse, and keyboard. @@ -51,7 +54,7 @@ Section: libdevel Architecture: any Multi-Arch: same Depends: ${misc:Depends}, - libsdl2 (= ${binary:Version}), + libsdl2-2.0-0 (= ${binary:Version}), libc6-dev, libgl1-mesa-dev Conflicts: libsdl-1.3-dev @@ -68,7 +71,7 @@ Section: debug Architecture: any Multi-Arch: same Depends: ${misc:Depends}, - libsdl2 (= ${binary:Version}), + libsdl2-2.0-0 (= ${binary:Version}), Description: Simple DirectMedia Layer debug files SDL is a library that allows programs portable low level access to a video framebuffer, audio output, mouse, and keyboard. diff --git a/debian/libsdl2.install b/debian/libsdl2-2.0-0.install similarity index 100% rename from debian/libsdl2.install rename to debian/libsdl2-2.0-0.install