QEMU-Devel Archive mirror
 help / color / mirror / Atom feed
From: Roman Bolshakov <r.bolshakov@yadro.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: "Kevin Wolf" <kwolf@redhat.com>,
	"Peter Maydell" <peter.maydell@linaro.org>,
	"Daniel P. Berrangé" <berrange@redhat.com>,
	"open list:Block layer core" <qemu-block@nongnu.org>,
	"QEMU Developers" <qemu-devel@nongnu.org>,
	"Max Reitz" <mreitz@redhat.com>,
	"Gerd Hoffmann" <kraxel@redhat.com>
Subject: Re: [PATCH] meson: Propagate gnutls dependency
Date: Fri, 8 Jan 2021 22:29:12 +0300	[thread overview]
Message-ID: <X/iyiCT39u5MCS2D@SPB-NB-133.local> (raw)
In-Reply-To: <CABgObfbYXoGVv4_KSzKR5J4XfJ2du9z77LEh1vrShz-q-O_t4g@mail.gmail.com>

On Thu, Jan 07, 2021 at 08:41:50PM +0100, Paolo Bonzini wrote:
> Il gio 7 gen 2021, 20:36 Roman Bolshakov <r.bolshakov@yadro.com> ha scritto:
> 
> > > No I think that Meson should simply explode link_whole libraries to their
> > > constituent objects.  This way duplicates are avoided.
> > >
> >
> > Ok. I've looked through related changes in meson and it flattens object
> > files implicitly for link_with/link_whole parameters of static_library:
> >
> >   https://github.com/mesonbuild/meson/pull/6030/files
> >
> > But qemu adds dependencies to source set and populates dependencies
> > parameter of static_library and declare_dependency and we get duplicate
> > symbols:
> >
> >   https://lists.gnu.org/archive/html/qemu-devel/2021-01/msg00411.html
> >
> > Perhaps it's a bug then.
> >
> 
> No, the same deduplication is not done for executables, because executables
> use libraries directly and not their object files.
> 

Paolo,

I tried to use extract_all_objects() to get all object files directly
but it doesn't work on dependency objects defined via
declare_dependency(). It works only on regular targets (libs and
executables). And as far as I understand the intention to have
declare_dependency() in QEMU was to specify public interface to avoid
some duplication. But meson doesn't have public/private notion for build
targets so if we drop declare_dependency we need to specify link_whole
in every user of a library that's had link_whole: declare_dependency()
and build files would become less lean. So I'm not sure how to proceed.

The proposed patch (in the subject) is the still the best we've got so
far that fixes macOS build immediately without much bigger wrestling
with meson.

-Roman


  reply	other threads:[~2021-01-08 19:53 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-02 12:52 [PATCH] meson: Propagate gnutls dependency Roman Bolshakov
2021-01-02 13:25 ` Peter Maydell
2021-01-02 14:16   ` Roman Bolshakov
2021-01-02 19:43   ` Paolo Bonzini
2021-01-04 17:24     ` Roman Bolshakov
2021-01-04 20:50       ` Paolo Bonzini
2021-01-05 14:37         ` Roman Bolshakov
2021-01-05 17:41           ` Paolo Bonzini
2021-01-07 11:41           ` Paolo Bonzini
2021-01-07 15:56             ` Roman Bolshakov
2021-01-07 16:23               ` Paolo Bonzini
2021-01-07 18:18                 ` Roman Bolshakov
2021-01-07 18:22                   ` Paolo Bonzini
2021-01-07 19:36                     ` Roman Bolshakov
2021-01-07 19:41                       ` Paolo Bonzini
2021-01-08 19:29                         ` Roman Bolshakov [this message]
2021-01-08 20:02                           ` Paolo Bonzini
2021-01-04 12:21   ` Daniel P. Berrangé
2021-01-04 12:30     ` Paolo Bonzini
2021-01-04 13:21     ` Peter Maydell
2021-01-04 14:40       ` Paolo Bonzini
2021-01-04 15:19         ` Peter Maydell
2021-01-04 17:49           ` Paolo Bonzini
2021-01-04 17:51             ` Peter Maydell

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=X/iyiCT39u5MCS2D@SPB-NB-133.local \
    --to=r.bolshakov@yadro.com \
    --cc=berrange@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-block@nongnu.org \
    --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 read-only IMAP folder(s) and NNTP newsgroup(s).