OSDN Git Service

meson: allow optional dependencies for block modules
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 1 Jun 2021 07:54:10 +0000 (09:54 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 4 Jun 2021 11:47:07 +0000 (13:47 +0200)
commit96acfb1f2552c24af6b3ed886daabe2bd3ceff2d
tree106a3217135752b3917637fa12e0a682d83b5e6c
parent5a95f5ce3cd5842cc8f61a91ecd4fb4e8d10104f
meson: allow optional dependencies for block modules

Right now all dependencies for block modules are passed to
module_ss.add(when: ...), so they are mandatory.  In the next patch we
will need to add a libm dependency to a module, but libm does not exist
on all systems.  So, modify the creation of module_ss and modsrc so that
dependencies can also be passed to module_ss.add(if_true: ...).

While touching the array, remove the useless dependency of the curl
module on glib.  glib is always linked in QEMU and in fact all other
block modules also need it, but they don't have to specify it.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
block/meson.build