ANGLE, which runs OpenGL ES on Direct3D 11 on Windows and on Metal on macOS, built for 64-bit and 32-bit Windows and for Apple silicon and Intel Macs. Lime uses it in place of the GPU's own OpenGL in applications built with the angle define, where it gives an OpenGL ES 3.0 context.
Lime includes this library itself when angle is defined, and copies libEGL and libGLESv2 into the application from the folder for its architecture:
ndll/Windows64/, for x64 Windows, beside the executablendll/Windows/, for x86 Windows, beside the executablendll/MacArm64/, for Apple silicon, into the bundle'sContents/Frameworks/ndll/Mac64/, for Intel Macs, into the bundle'sContents/Frameworks/
Lime's native library has to be rebuilt with the define as well, which builds it against the headers in include/:
lime rebuild windows -Dangle
lime rebuild mac -Dangle
On Windows, ANGLE compiles shaders with the d3dcompiler_47.dll that comes with Windows 10 and later, so it is not included. On macOS, it needs macOS 13 or later. Where a GPU is too old for OpenGL ES 3.0, Lime asks ANGLE for 2.0.
haxelib install lime-angle
ANGLE has no binary releases, so these are built here. The binaries are ANGLE at the commit in ANGLE_COMMIT, the head of the chromium/8127 branch that Chrome 158 was released from, built by scripts/Build.hx: for Windows with only the Direct3D 11 back end and with the C runtime linked in, and for macOS with only the Metal back end. The Build ANGLE workflow runs the script on GitHub Actions, and the files here come from its lime-angle artifact. The headers in include/ are ANGLE's own at that commit.
The script runs with Haxe 4, from this folder, and builds a target on a host of the same platform, so Windows builds on Windows and macOS builds on a Mac, which builds both Mac architectures:
haxe -cp scripts --run Build windows x64
haxe -cp scripts --run Build mac arm64
haxe -cp scripts --run Build package <build folder>... puts builds together as they are here. The script's own comment lists what each build needs.
To move to another ANGLE, change ANGLE_COMMIT, and replace ndll/, include/ and LICENSE.md with what the workflow builds.
ANGLE is under a BSD license. See LICENSE.md for it and the licenses of what ANGLE is built with.