Debian/Ubuntu linkers are more strict that other distros requiring glib
to be linked explicitly.

macOS needs -export-dynamic instead of -Wl,--export-dynamic

Signed-off-by: Daniel P. Berrangé <berra...@redhat.com>
---

Pushed as a CI build fix for Debian/Ubuntu/macOS

 src/qemu/Makefile.inc.am | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/src/qemu/Makefile.inc.am b/src/qemu/Makefile.inc.am
index c6b04c3217..d04a87e659 100644
--- a/src/qemu/Makefile.inc.am
+++ b/src/qemu/Makefile.inc.am
@@ -253,6 +253,9 @@ bin_PROGRAMS += virt-qemu-run
 
 virt_qemu_run_SOURCES = $(QEMU_SHIM_SOURCES)
 
-virt_qemu_run_LDADD = libvirt.la
-virt_qemu_run_LDFLAGS = -Wl,--export-dynamic
+virt_qemu_run_LDADD = \
+       libvirt.la \
+       $(GLIB_LIBS) \
+       $(NULL)
+virt_qemu_run_LDFLAGS = -export-dynamic
 endif WITH_QEMU
-- 
2.24.1

Reply via email to