for cross-compiling macos executables on Linux? I have not tried it, but if it works, it would be a way to keep all the CI build infrastructure in docker containers.
If it is worth investigating, we would probably need Claudine to look at the Xcode/SDK license and verify it is a valid use of the license. (I suspect it would be although we might need to run the docker image on Apple hardware.)
I had been thinking about using Darling which is like WINE, but targeting macOS. This helps with the VTK problem where we compile host tools as well (though VTK has solutions for this, CI for it would be more painful than I’d like). It would allow us to just grab an Xcode and use it directly too. We’d then take the build from the Linux machine and test it on real macOS.
Not that I dislike Darling (it seems nice), but isn’t cross-compilation (including host-side tools) something VTK and ParaView have had to deal with on various HPC platforms? If Darling works, it seems cleaner… but it seems like a project that will require a lot of work (initial development and ongoing updates for new macos releases) compared to cross-compiling. Is the Darling project funded or backed by a group committed to maintaining it?
AFAIK, the only cross-compile targets VTK and ParaView actually have to deal with anymore are iOS and Android these days. Blue Gene was the only must-be-cross-compiled HPC platform and that isn’t really used anymore. Modern HPC platforms do native compilation these days.
Even so, I wouldn’t want to use macOS-from-Linux as our cross-compiling test case since “no one” actually does that in the real world.
I don’t know what its development status is. I was planning on doing more thorough investigation as part of VTK’s migration to gitlab-ci since it will strain the available macOS hardware more than any other project anyways.
That would not be as much of an issue for us (although it would be nice to use cheaper hardware for compilation). The problem is that we want to containerize as much of the build process as possible.
Just stumbled upon this thread and it’s a topic close to my heart. I’ve been diving into CI/CD pipelines lately and the challenges of ensuring seamless compatibility across different platforms are real. Kudos to you, dcthomp, for bringing up the macOS compatibility issue. It’s a pain point for many.
Regarding the project you shared, I haven’t personally used it, but the concept sounds promising. Cross-compiling macOS executables on Linux could indeed simplify CI workflows significantly. However, as you rightly pointed out, the Xcode/SDK license aspect needs a thorough look.
@dcthomps, I’d suggest reaching out to Claudine, as you mentioned, to get clarity on the licensing aspect. It’s always better to be safe and ensure we’re not breaching any terms. And you’re correct about the potential need to run the Docker image on Apple hardware for the best results.
In my experience, experimenting with such solutions is the best way to learn. I’ve had my share of trial and error, and it’s all part of the journey.