Compiling GMP with clang

Marc Glisse marc.glisse at inria.fr
Sun Nov 30 11:55:05 UTC 2014


On Sat, 29 Nov 2014, Torbjörn Granlund wrote:

> 3. Link errors on some arm32 systems.  We have not investigates this.
>   Help is welcome. Failure log:
>   https://gmplib.org/devel/testmachines/build/failure/armv5.gmplib.org-stat-clang-clang++:standard.txt

#include <stdexcept>
int main(){throw std::invalid_argument("hello");}

$ clang++ -target arm-linux-gnueabi main.cc
$ clang++ -target arm-linux-gnueabi main.cc -O -latomic
$ clang++ -target arm-linux-gnueabi main.cc -O
/tmp/main-d6b7a1.o: In function `main':
main.cc:(.text+0x84): undefined reference to `__atomic_fetch_add_4'

It should be possible to test this in configure.

I don't know how relevant armv5 is to GMP though.

(I also killed lt-reuse after 5 minutes, but it might just be that long)

-stdlib=libc++ testing is complicated because of 
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=771512

-- 
Marc Glisse


More information about the gmp-devel mailing list