From: Peter Maydell <peter.maydell@linaro.org>
To: Paz Offer <poffer@nvidia.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: What is the correct way to add linker dependency to QEMU build system?
Date: Thu, 29 Feb 2024 17:34:22 +0000 [thread overview]
Message-ID: <CAFEAcA8S-uONJyR5nKh=HGQwKNUtT4VB+VYBh_dp3_3bjZfmfg@mail.gmail.com> (raw)
In-Reply-To: <MW4PR12MB69979E8A2E0F9B62D6C2A703A05F2@MW4PR12MB6997.namprd12.prod.outlook.com>
On Thu, 29 Feb 2024 at 16:10, Paz Offer <poffer@nvidia.com> wrote:
> I want to add library 'libdl' to be linked with QEMU build for a particular target (e.g. - qemu-system-arm).
> Using meson I would typically do 'compiler.find_library(...)', and later add the returned dependency to the binary dependencies list.
> However, in QEMU I understand that these configurations are done in the './configure' file?
>
> What would be the correct way to do this?
If you can do the job using the glib g_module_open()/
g_module_symbol() functions (which is how QEMU itself does
loading of plugin and module DLLs, and which on Unix hosts
are pretty much wrappers around dlopen/dlsym) then you
don't need to link against libdl at all.
If this is for something you're planning to upstream
then it might be worth talking at a higher level about
what you're aiming to do. (If it's for something downstream
that you don't plan to ever upstream then you can do
whatever's easiest for you, of course.)
-- PMM
next prev parent reply other threads:[~2024-02-29 17:35 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-29 16:09 What is the correct way to add linker dependency to QEMU build system? Paz Offer
2024-02-29 17:02 ` Alex Bennée
2024-02-29 21:22 ` Paolo Bonzini
2024-02-29 17:34 ` Peter Maydell [this message]
2024-02-29 19:00 ` Paz Offer
2024-03-06 6:05 ` Paz Offer
2024-03-06 9:28 ` Alex Bennée
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='CAFEAcA8S-uONJyR5nKh=HGQwKNUtT4VB+VYBh_dp3_3bjZfmfg@mail.gmail.com' \
--to=peter.maydell@linaro.org \
--cc=poffer@nvidia.com \
--cc=qemu-devel@nongnu.org \
/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;
as well as URLs for NNTP newsgroup(s).