Cross compile GMP for Apple Silicon

Hans Åberg haberg-1 at
Sun Nov 22 16:45:25 UTC 2020

> On 22 Nov 2020, at 15:44, Pierre Chatelier <pierre at> wrote:
> I succeeded in cross-compiling GMP from amd64 on a x86_64 build system.
> I had overloads of defaults tools in /opt because I use macports.
> Here is my build script if it can help others.
> For the sake of clarity, I have removed all macros, to show absolute paths. For better compatibility, tools like "xcode-select -p" could be used.
> export CC=clang
> export CXX=clang

Use absolute paths for these, or cc and c++: Those in /usr/bin/ are not the real clang, but an Apple inhouse version.

More information about the gmp-discuss mailing list