make check errors on recent MacOS versions appear to be due to new default linker in XCode

Ken Cunningham ken.cunningham.webuse at gmail.com
Tue Oct 1 22:34:17 CEST 2024


Hello, 

Macports developer here.

The recent issues with "make check" that show up only when building on recent MacOS Intel systems with assembly enabled appear to be related to the new linker Apple released.

They can be eliminated by using the old linker, for example by doing this prior to configuration and build:

export LDFLAGS='-Wl,-ld_classic'

These errors appear to have absolutely nothing to do with the compiler -- clang or gcc, all compilers that are set up to use the new linker show the same errors in make check.

There are reported issues with the new linker in other math-heavy software, for example:

https://www.scivision.dev/xcode-ld_classic/


At this moment, I am not sure if the new linker is at fault, or if the new linker is bringing out errors with the gmp assembly and that is what needs fixing.

Someone who can debug these make check errors with the new linker will be needed to see what is going on. Perhaps that might be someone at Apple, and Apple bugs are reported to them via "RADAR" reports.

In the meantime, the old linker can be forced, as above, however that old linker is slated to be removed from xcode in due course, so hopefully whatever is causing the issue can be dealt with before that happens.

Best,

Ken Cunningham


More information about the gmp-bugs mailing list