Closed RenaudFondeur closed 6 months ago
When building the objective C files during the VM build, cmake by default tried to use the MacOS12 SDK, failing compilation.
We worked it around by explicitly setting -DCMAKE_OSX_SYSROOT=... as specified here: https://stackoverflow.com/questions/10165335/can-cmake-specify-the-base-sdk-on-mac-os-x.
We also saw that CMake provides already support to detect the SDK and that we should use https://cmake.org/cmake/help/latest/variable/CMAKE_OSX_DEPLOYMENT_TARGET.html#variable:CMAKE_OSX_DEPLOYMENT_TARGET to specify the target instead of setting the compiler flag manually like this https://github.com/pharo-project/pharo-vm/blob/48ddfeee791ca9bcdf3d65c10d25e54e732bebec/CMakeLists.txt#L263.
Otherwise CMake can override it and provoke this issue
@RenaudFondeur I fixed this in the last PR, would you mind if this works out of the box in your machine?
(you will need to pull)
When building the objective C files during the VM build, cmake by default tried to use the MacOS12 SDK, failing compilation.
We worked it around by explicitly setting -DCMAKE_OSX_SYSROOT=... as specified here: https://stackoverflow.com/questions/10165335/can-cmake-specify-the-base-sdk-on-mac-os-x.
We also saw that CMake provides already support to detect the SDK and that we should use https://cmake.org/cmake/help/latest/variable/CMAKE_OSX_DEPLOYMENT_TARGET.html#variable:CMAKE_OSX_DEPLOYMENT_TARGET to specify the target instead of setting the compiler flag manually like this https://github.com/pharo-project/pharo-vm/blob/48ddfeee791ca9bcdf3d65c10d25e54e732bebec/CMakeLists.txt#L263.
Otherwise CMake can override it and provoke this issue