[RFC PATCH v2 0/5] meson: Pass objects to declare_dependency()

Paolo Bonzini posted 5 patches 6 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20240527104937.30443-1-pbonzini@redhat.com
Maintainers: "Alex Bennée" <alex.bennee@linaro.org>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, Thomas Huth <thuth@redhat.com>, Wainer dos Santos Moschetta <wainersm@redhat.com>, Beraldo Leal <bleal@redhat.com>, Kevin Wolf <kwolf@redhat.com>, Hanna Reitz <hreitz@redhat.com>, "Daniel P. Berrangé" <berrange@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>, "Marc-André Lureau" <marcandre.lureau@redhat.com>, Richard Henderson <richard.henderson@linaro.org>, Laurent Vivier <lvivier@redhat.com>, Gerd Hoffmann <kraxel@redhat.com>
docs/devel/build-system.rst         |   8 +--
meson.build                         | 100 ++++++++++++++--------------
stubs/blk-exp-close-all.c           |   2 +-
.gitlab-ci.d/buildtest-template.yml |   2 -
.gitlab-ci.d/buildtest.yml          |   2 -
block/meson.build                   |   2 +-
gdbstub/meson.build                 |   6 +-
io/meson.build                      |   2 +-
pythondeps.toml                     |   2 +-
storage-daemon/meson.build          |   3 +-
tcg/meson.build                     |   8 +--
tests/Makefile.include              |   2 +-
tests/qtest/libqos/meson.build      |   3 +-
ui/meson.build                      |   2 +-
14 files changed, 66 insertions(+), 78 deletions(-)
[RFC PATCH v2 0/5] meson: Pass objects to declare_dependency()
Posted by Paolo Bonzini 6 months ago
This is a working version of Akihiko's changes to declare internal
dependencies as objects instead of static libraries.  This is a safer
way to drop the ".fa" library suffix, as it drops usage of the
pseudo static libraries altogether.

Static libraries trigger an issue in GNU ld, where GNU ld keeps all
object files referenced by thin archives open.  This can cause it to
exceed the open file limit.  Another problem with link_whole is the
suboptimal handling of nested dependencies, which is described in
https://github.com/mesonbuild/meson/pull/8151 and
https://github.com/mesonbuild/meson/pull/11198.

I'm keeping this as RFC because patch 2 ("meson: move block.syms
dependency out of libblock") is a bit ugly.  I think it's _less_
ugly than what patch 4 reverts, but I am open to comments.

As Akihiko noted, fork-fuzz is gone so it is possible to just remove
the .fa suffixes.  This series can be evaluated independently from
that.

Paolo

Akihiko Odaki (2):
  meson: Pass objects and dependencies to declare_dependency()
  Revert "meson: Propagate gnutls dependency"

Paolo Bonzini (3):
  meson: move shared_module() calls where modules are already walked
  meson: move block.syms dependency out of libblock
  meson: Drop the .fa library suffix

 docs/devel/build-system.rst         |   8 +--
 meson.build                         | 100 ++++++++++++++--------------
 stubs/blk-exp-close-all.c           |   2 +-
 .gitlab-ci.d/buildtest-template.yml |   2 -
 .gitlab-ci.d/buildtest.yml          |   2 -
 block/meson.build                   |   2 +-
 gdbstub/meson.build                 |   6 +-
 io/meson.build                      |   2 +-
 pythondeps.toml                     |   2 +-
 storage-daemon/meson.build          |   3 +-
 tcg/meson.build                     |   8 +--
 tests/Makefile.include              |   2 +-
 tests/qtest/libqos/meson.build      |   3 +-
 ui/meson.build                      |   2 +-
 14 files changed, 66 insertions(+), 78 deletions(-)

-- 
2.45.1