
-------- Original Message -------- Subject: ac_check_gmp.m4 in ppl Date: Mon, 27 Oct 2003 13:49:20 +0100 From: Bruno Haible bruno@clisp.org To: Roberto Bagnara bagnara@cs.unipr.it
Hi,
While compiling ppl-0.5 I had problems telling the configure script where my libgmp is installed. Just
--with-gmp-includes=/packages/gnu/include --with-gmp-lib=/packages/gnu/lib
wasn't enough, because 1. the test program is linked without any -L option, 2. the test program is linked without any -rpath option and then immediately run - which doesn't work when a program depends on shared libraries in nonstandard locations. As a workaround, I had to use
LDFLAGS="-L/packages/gnu/lib -Wl,-rpath,/packages/gnu/lib" \ ./configure --prefix=/packages/gnu \ --with-gmp-includes=/packages/gnu/include --with-gmp-lib=/packages/gnu/lib
You could make this easier by using AC_LIB_LINKFLAGS(gmpxx, gmp) in your configure.ac file. The AC_LIB_LINKFLAGS macro is defined in gettext-0.12.1/autoconf-lib-link/m4/*.m4 from the GNU gettext-0.12.1 distribution.
Best regards, Bruno