mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-04-24 08:15:50 +00:00
Fix joystick (/dev/input/xxx) support on FreeBSD
Backportf8ad4abefrom main branch. When switching to CMake, src/joystick/linux/SDL_sysjoystick.c file got excluded from FreeBSD builds, losing support for /dev/input/xxx devices. See also: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=279907 and: https://github.com/libsdl-org/SDL/pull/10087 (cherry picked from commitab5740bde2)
This commit is contained in:
committed by
Sam Lantinga
parent
53cf48f505
commit
f08f458896
@@ -1674,7 +1674,7 @@ elseif(UNIX AND NOT APPLE AND NOT RISCOS AND NOT HAIKU)
|
||||
if(FREEBSD OR NETBSD OR OPENBSD OR BSDI)
|
||||
CheckUSBHID()
|
||||
endif()
|
||||
if(LINUX AND HAVE_LINUX_INPUT_H AND NOT ANDROID)
|
||||
if((LINUX OR FREEBSD) AND HAVE_LINUX_INPUT_H AND NOT ANDROID)
|
||||
set(SDL_JOYSTICK_LINUX 1)
|
||||
file(GLOB JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/linux/*.c ${SDL2_SOURCE_DIR}/src/joystick/steam/*.c)
|
||||
list(APPEND SOURCE_FILES ${JOYSTICK_SOURCES})
|
||||
|
||||
Reference in New Issue
Block a user