We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 5407

Summary: SDL2 does not build on MacOS
Product: SDL Reporter: Jason <Jason.carr01>
Component: joystickAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: major    
Priority: P2 CC: sezeroz
Version: 2.0.14   
Hardware: x86_64   
OS: Mac OS X (All)   

Description Jason 2020-12-20 18:30:25 UTC
Using the latest development version, building SDL is failing on MacOS 11 because CMake is not including the files under "src/joystick/darwin/*"


My solution was to update lines 1704 and 1705 of CMakeLists.txt from

file(GLOB JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/darwin/*.c)
file(GLOB JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/iphoneos/*.m)

to

file(GLOB JOYSTICK_SOURCES "${SDL2_SOURCE_DIR}/src/joystick/darwin/*.c" "${SDL2_SOURCE_DIR}/src/joystick/iphoneos/*.m")
Comment 1 Ozkan Sezer 2020-12-20 18:55:18 UTC
Should be fixed by https://hg.libsdl.org/SDL/rev/54718b074123
If not, please drop a note here.