I’m attempting to build and run a project on MacOS that uses SDL2 (see https://github.com/FWGS/xash3d/issues/350 for the full saga), and I’m running into an issue where the application fails to load the SDL2 dylib because of an incorrect code signature. The error I get is the following:
Sys_Warn: Could not load client library:
dlopen(valve/cl_dlls/client.dylib, 1): Library not loaded: /usr/local/lib/libSDL2-2.0.0.dylib
Referenced from: /Users/vesper/Documents/afterburner/build/pkg/usr/local/lib/xash3d/valve/cl_dlls/client.dylib
Reason: no suitable image found. Did find:
../../../../libSDL2-2.0.0.dylib: code signature invalid for '../../../../libSDL2-2.0.0.dylib'
Failed to find library client.dylib
dlopen(client.dylib, 1): Library not loaded: /usr/local/lib/libSDL2-2.0.0.dylib
Referenced from: /Users/vesper/Documents/afterburner/build/pkg/usr/local/lib/xash3d/valve/cl_dlls/client.dylib
Reason: no suitable image found. Did find:
../../../../libSDL2-2.0.0.dylib: code signature invalid for '../../../../libSDL2-2.0.0.dylib'
To compile and build this particular project I followed the steps in its CI scripts, which do seem to work correctly in general. The .dylib comes from the MacOS SDL framework that’s available for download on the SDL site, and is apparently obtained during compilation/installation of this project by copying and renaming the SDL2.framework/SDL2
file to be a .dylib. I’m aware it’s not technically 2.0.0, but that apparently is the file name the application is expecting, and I wouldn’t have thought that would cause an issue with code signing.
Are these library signing errors an issue on my part, or is the framework not code not signed correctly?