Compiling gmp 4.2.4

Torbjorn Granlund tg at swox.com
Fri Dec 26 14:36:49 CET 2008


Rich Smrcina <rsmrcina at wi.rr.com> writes:

  I'm trying to compile gmp 4.2.4 on the s390x platform. An RPM is available of an older 
  version, but I need the header files for another package, and there is no gmp-devel 
  package for s390x.
  
  My gcc is 4.1.2.  Configure and make seem to run fine, during 'make check' I get this error:
  
  gcc -O2 -fomit-frame-pointer -o .libs/t-bswap t-bswap.o  ./.libs/libtests.a 
  /home/rks0/gmp-4.2.4/.libs/libgmp.so ../.libs/libgmp.so
  /home/rks0/gmp-4.2.4/.libs/libgmp.so: undefined reference to `sdiv_qrnnd'
  collect2: ld returned 1 exit status
  make[4]: *** [t-bswap] Error 1
  make[4]: Leaving directory `/home/rks0/gmp-4.2.4/tests'
  make[3]: *** [check-am] Error 2
  make[3]: Leaving directory `/home/rks0/gmp-4.2.4/tests'
  make[2]: *** [check-recursive] Error 1
  make[2]: Leaving directory `/home/rks0/gmp-4.2.4/tests'
  make[1]: *** [check-recursive] Error 1
  make[1]: Leaving directory `/home/rks0/gmp-4.2.4'
  make: *** [check] Error 2
  
  Any tips on how to get past this?
  
It is strange.

The reference to sdiv_qrnnd is presumably from
mpn/generic/udiv_w_sdiv.c, and longlong.h is setup to #define it.

Either your build picks up some incompatible longlong.h, or
your compiler does not #define the symbols longlong.h checks.

Or perhaps s390x is a 64-bit system?  There are some hints in that
direction.  GMP has not been ported to that system.

-- 
Torbjörn


More information about the gmp-bugs mailing list