sdk-ng icon indicating copy to clipboard operation
sdk-ng copied to clipboard

Evaluate feasibility of creating macOS universal binary

Open stephanosio opened this issue 3 years ago • 1 comments
trafficstars

macOS allows single executable to contain the images for multiple architectures (i.e. x86_64 and AArch64) -- this is known as a "universal binary."

Evaluate the feasibility of creating a Zephyr SDK distribution bundle containing "universal binaries" so that users do not need to manually choose the host platform type.

stephanosio avatar Jul 15 '22 12:07 stephanosio

For the stuff that uses cmake, this should be as simple as using CMAKE_OSX_ARCHITECTURES=arm64;x86_64.

For everything else, assuming you can generate the individual arch binaries, the "lipo" tool can put them together for you.

The toolchains are the trickier part, and not on the distribution side - there are plenty of things that try to extract arches from the binary name, or assume that a single binary can't be two different toolchains, or ...

dberlin avatar Sep 04 '22 14:09 dberlin