From: Andrew Pinski via Gdb <gdb@sourceware.org>
To: "Vahedi, Shahab" <Shahab.Vahedi@amd.com>
Cc: "gdb@sourceware.org" <gdb@sourceware.org>
Subject: Re: Statically linking with libgmp and libmpfr
Date: Fri, 16 May 2025 02:42:25 -0700 [thread overview]
Message-ID: <CA+=Sn1=uSmdEGR4Vb8vyn5-zd7jX3tx3EMuFRxsivJWBbAh5LQ@mail.gmail.com> (raw)
In-Reply-To: <58524a52-7925-4ea9-8b3f-efe64dc750e9@amd.com>
On Fri, May 16, 2025 at 1:57 AM Vahedi, Shahab via Gdb
<gdb@sourceware.org> wrote:
>
> I've managed to _work around_ this by populating a "static only" lib dir
> and pointing the "configure" to it:
>
> $ mkdir -p /only/static/libs
> $ cp /usr/lib/libgmp.a /only/static/libs
> $ cp /usr/lib/libmpfr.a /only/static/libs
>
> $ tree /only/static/libs
> /only/static/libs
> |-- libgmp.a
> `-- libmpfr.a
>
>
> $ configure ... \
> --with-gmp-lib=/only/static/libs \
> --with-mpfr-lib=/only/static/libs
> $ make
>
> $ libtree -vv gdb/gdb
> [ no signs of gmp or mpfr ]
>
>
> I still am interested in an out-of-the-box approach, if any, like GDB <= 13.2.
The out of the box approach is to put the GMP/MPFR sources in the top
level directory and that will build gmp/mpfr (static only) and link
against those .
So don't build GMP/MPFR separately when building gdb.
Thanks,
Andrew
>
>
> Cheers,
> Shahab
next prev parent reply other threads:[~2025-05-16 9:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-16 8:24 Vahedi, Shahab via Gdb
2025-05-16 8:55 ` Vahedi, Shahab via Gdb
2025-05-16 9:42 ` Andrew Pinski via Gdb [this message]
2025-05-16 12:49 ` Vahedi, Shahab via Gdb
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CA+=Sn1=uSmdEGR4Vb8vyn5-zd7jX3tx3EMuFRxsivJWBbAh5LQ@mail.gmail.com' \
--to=gdb@sourceware.org \
--cc=Shahab.Vahedi@amd.com \
--cc=pinskia@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox