Newer Apple SDK expect __ENVIRONMENT_OS_VERSION_MIN_REQUIRED__ to be
defined which LLVM before 17 don't do.
By upgrading to newer LLVM, we raise a bug in libpng which has not been
fixed in the version we use.
Finally update osxcross to take the correct compiler-rt branch.
Updating SDK implies to update LLVM to version 16 as it fails to build
with older versions (commit f4be5ed6a3fef0b2b0c60b29e1c0638926638d28).
LLVM version 16 triggers an incompatibility between compiler-rt (which
uses C++17 features) and the old i386 MacOS SDK.
This new compiler-rt also needs CMake helpers and new arguments to
properly build as we wish.
GCW0 toolchain can't be built anymore as Mesa build requires Python 2
which is not available anymore.
Helper packages got upgraded and configure arguments and several
patches must be updated.
New GCC defaults to a too modern C++ version to compile old GCC.
Debian now provides a modern enough CLang hence switching to it.
For iPhone where we need compiler-rt, try several patch versions when
the compiler one is not available (CLang PPA is development build)
Upgrade cctools-port at the same time.
- Update SDK versions using Xcode 12.2
- Add LDID to osxcross as ARM is now supported by MacOSX11.0 SDK
- Upgrade host triples
- Fix a bad copy-paste in platform configuration (x86_64 instead of
i386)
This platform is a little complex.
First, it pulls its SDKs from toolchains/apple_sdks.
Second, there is two toolchains for amd64 and i386 (an older SDK as the
last ones have dropped i386 support).
The CLang provided by Debian is too old for last SDKs so there is
multiple choices avoailable:
- use Debian clang,
- use official clang packages,
- use osxcross clang build script (take a long time).
Third, there is a macosx-common image which contains all scripts which
are needed by all toolchains: that is osxcross, osxcross-clang (to build
clang) and libsdl2 (as sdl2-config is buggy in MacPorts).
Finally, there is a m4 script to build all the toolchains.
The Dockerfile.m4 in toolchain directory is only there to do some tuning
on the build.
The same is done for workers.