Linking to OSX frameworks does not work
You can do e.g. find_library(SDL2LIB SDL2)
and it may return the framework (e.g. /usr/lib/apple/SDKs/MacOSX10.11.sdk/Library/Frameworks/SDL2.framework
)
According to the docu:
If the library found is a framework, then will be set to the full path to the framework /A.framework. When a full path to a framework is used as a library, CMake will use a -framework A, and a -F to link the framework to the target.
However this is not happening. I was just compiling a library linked against the above and it tries to link against that folder. No -framework
is added.
Searching through the CMake code I could find some handling of that case but it doesn't work here. Using 3.13.2.
Edited by Alexander Grund