[build] Unable to build a Mach-O universal binary with 2 architectures when building from source
zeusdeux opened this issue · 3 comments
WARNING: Please, read this note carefully before submitting a new issue:
It is important to realise that this is NOT A SUPPORT FORUM, this is for reproducible BUGS with raylib ONLY.
There are lots of generous and helpful people ready to help you out on raylib Discord forum or raylib reddit.
Remember that asking for support questions here actively takes developer time away from improving raylib.
Please, before submitting a new issue verify and check:
- I tested it on raylib version 5.0
- I checked there is no similar issue already reported
- I checked the documentation on the wiki
- My code has no errors or misuse of raylib
Issue description
Hi folks! I am attempting to build raylib-5.0 from source and upon following the instructions in https://github.com/raysan5/raylib/wiki/Working-on-macOS#without-xcode---building-statically, I am unable to get a Mach-O universal binary with 2 architectures
built. Instead the built libraylib.a
is a current ar archive
. Which even upon running ranlib ./libraylib.a
doesn't give me a Mach-O universal binary.
Environment
macos Ventura 13.6.3 on Intel x64 silicon
Issue Screenshot
Locally built raylib
Raylib prebuilt binary for osx
Code Example
- Download the tarball or zip file of version 5.0 from releases
- Unzip and cd into the
src/
folder export MACOSX_DEPLOYMENT_TARGET=13.6.3
make
Nvm, sorted.
For anyone that runs into this — build libs for whatever set of platforms for macOS and run the libs together into lipo -create
@zeusdeux Thanks for reporting! Actually, that's how it's done by the CD system: https://github.com/raysan5/raylib/blob/master/.github/workflows/macos.yml#L85