I'm trying to cross-compile from Linux to MacOS using osxcross and I get this errors message:
Attempting to use @rpath without CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG being
set. This could be because you are using a Mac OS X version less than 10.5
or because CMake's platform configuration is corrupt.
However, manually specifying -DCMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG="-Wl,-rpath," doesn't do anyting.
variable_watch point to the value being correctly set, and when reset to empty in
https://gitlab.kitware.com/cmake/cmake/-/blob/master/Modules/CMakeGenericSystem.cmake#L6
Which is invoked as part of project(...) declaration (at least according to call stack).
So, besides hardcoding (which is a very dirty hack) this variable after the call to project nothing I've tried appeared to work.
Is there some way to fix this?