Statically linking with libgmp and libmpfr

"Vahedi, Shahab via Gdb" <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <[email protected]>
Up to and including GDB 13.2, it was possible to statically link GDB with
GMP and MPFR libraries. It was as simple as:

$ ./configure ... --with-libgmp-type=static --with-libmpfr-type=static

However, that all changed after this commit [1]. Those parameters are
ignored after this patch. I've tried the following approaches to no
avail (See [2] why they don't work):


$ ./configure GMPLIBS="/usr/lib/libmgmp.a /usr/lib/libmpfr.a"
$ ./configure --with-gmp-lib=/usr/lib/libgmp.a --with-mpfr-lib=...
$ ./configure --with-gmp-lib=-l:libgmp.a --with-mpfr-lib=-l:libmpfr.a


Is anyone aware of other ways to do so? 


Cheers,
Shahab


[1] Use toplevel configure for GMP and MPFR for gdb
https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=99118062785


[2] reasons that the illustrated alternatives don't work:

- configure GMPLIBS=...: the GMPLIBS is ignored and not transferred from
                         the top-level configure to gdb/configure

- --with-gmp-lib=/usr/lib/libgmp.a: the value is supposed to be a dir

- --with-gmp-lib=-l:libgmp.a: it gets prefixed with "-L" in configure
                              (-L-l:libgmpa.a)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.