Fix joystick (/dev/input/xxx) support on FreeBSD

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
This commit is contained in:
Ganael Laplanche 2024-06-22 15:55:17 +02:00 committed by Sam Lantinga
parent 99d28ca485
commit f8ad4abe4e
1 changed files with 1 additions and 1 deletions

View File

@ -1732,7 +1732,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)
sdl_glob_sources(
"${SDL3_SOURCE_DIR}/src/joystick/linux/*.c"