'make check' failure with disabled shared libraries on Mac OSX 10.6

listboss listboss at gmail.com
Sun Nov 28 10:48:53 CET 2010


Hello everyone,

I am trying to figure out why using static version of gmp library in
my project breaks my code but linking against a shared version of gmp
library works just fine (gmp-5.0.1 both .a and .dylib are built at the
same time).
This happens on a MacBookPro 1,1 (Intel Core Duo) running OSX 10.6.5
(32-bit) and I am basically trying to test CGAL libraries (cgal.org).
The above problem happens neither on 64-bit OSX nor on Linux(32 or 64)!
So I thought I'd configure gmp once with disabled shared and once with
disabled static options and continue my debugging from there. I
started with disabling shared libraries as it was mentioned here too
(http://gmplib.org/manual/Known-Build-Problems.html#Known-Build-Problems)

However, when I do following on my MacBook, the 'make check' step fails:

$ ./config.guess
pentiumm-apple-darwin10.5.0
$ ./configure --disable-shared
$ make; make check
....
libtool: link: gcc -std=gnu99 -m32 -O2 -pedantic -fomit-frame-pointer
-mtune=pentium3 -march=pentium3 -o t-bswap t-bswap.o
./.libs/libtests.a /Users/hamid/Downloads/gmp-5.0.1/.libs/libgmp.a
../.libs/libgmp.a
Undefined symbols:
  "_calling_conventions_save_esi", referenced from:
      _calling_conventions in libtests.a(x86call.o)
      _calling_conventions in libtests.a(x86call.o)

I have also tried:
--build=pentium-apple-darwin10.5.0 ABI=32 --disable-shared
--build=pentiumm-apple-darwin10.5.0 ABI=32 --disable-shared

Of course removing --disable-shared results in a successful 'make check' step.
(--disable-static works too)

So my questions are
1- How can I get a successful 'make check' when using --disable-shared
2- What do you suggest to check/debug as a starting point in my code
in which static linking of gmp fails my code but dynamic linking does
not ?

thanks in advance for your time


More information about the gmp-discuss mailing list