Closed kevinbioj closed 3 years ago
Shooting in the dark here:
The Graphics library uses the Xlib API for drawing things. On macOS, the Xlib API is implemented by the xquartz package provided by Homebrew.
Are you sure your xquartz library is an ARM binary? could it be an x86-64 binary? It all depends on which version of Homebrew is installed on your machine.
Also, you could try to trace the dynamic loading process using these tricks: https://craftware.xyz/tips/Dynamic-libraries-loading.html
Looks like you were right 👀 My XQuartz installation was indeed an x86 build according to macOS's activity monitor. Hopefully, there was an update (2.8.0_rc2) and it looks like it's now running natively. After that I've reinstalled the graphics library, now everything works fine! Thanks.
Hey!
I've been trying to play with OCaml on ARM-based macOS, but I've been facing an issue which can be problematic for my usage. Everything works fine, except for the graphics library which completely refuse to load up. OCaml runs on version 4.12.0 freshly installed from
opam
, packagescore
andgraphics
were added too to bring up graphics functionnality.I use OCaml's top find in order to get my libraries loaded, here is a sample code:
While this code works on my native Linux (Debian) system, and my Debian on Windows 10 through WSL2... it does not work here.
I do get this weird error, apparently a library isn't providing what it should which leads OCaml to fail up loading it... but I can't find anything related when searching on Google. Side note, I haven't got any error or warning then opam was installing OCaml, core and graphics packages - aside from the classic
pkg-config
I had to install on all my systems anyway.I'm using a late-2020 MacBook Air with an M1 chip, on macOS Big Sur 11.2.2. I'm up to you if you need any more information or debug files.
Thanks!