aboutsummaryrefslogtreecommitdiff
path: root/stubs
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2024-10-21 18:07:16 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2024-10-30 16:30:56 +0100
commit388b849fb6c33882b481123568995a749a54f648 (patch)
tree89773dd0400aa03c5db9db8df4f819aabaa6af1c /stubs
parent58d49b5895f2e0b5cfe4b2901bf24f3320b74f29 (diff)
stubs: avoid duplicate symbols in libqemuutil.a
qapi_event_send_device_deleted is always included (together with the rest of QAPI) in libqemuutil.a if either system-mode emulation or tools are being built, and in that case the stub causes a duplicate symbol to appear in libqemuutil.a. Add the symbol only if events are not being requested. Cc: qemu-stable@nongnu.org Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Tested-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'stubs')
-rw-r--r--stubs/meson.build7
1 files changed, 6 insertions, 1 deletions
diff --git a/stubs/meson.build b/stubs/meson.build
index 772a3e817d..e91614a874 100644
--- a/stubs/meson.build
+++ b/stubs/meson.build
@@ -55,7 +55,12 @@ endif
if have_user
# Symbols that are used by hw/core.
stub_ss.add(files('cpu-synchronize-state.c'))
- stub_ss.add(files('qdev.c'))
+
+ # Stubs for QAPI events. Those can always be included in the build, but
+ # they are not built at all for --disable-system --disable-tools builds.
+ if not (have_system or have_tools)
+ stub_ss.add(files('qdev.c'))
+ endif
endif
if have_system