On Fri, Apr 3, 2020 at 5:16 PM Rafael Fonseca <r4f4rfs(a)gmail.com> wrote:
virDomain is still WIP because it causes some linking problem I am
still
investigating.
Gonna ask here since you guys might have some idea from the top of
your heads to help me.
I converted virDomain to GObject. However, when linking I get the
following error:
CC libvirt_lxc_la-libvirt-lxc.lo
CCLD libvirt-lxc.la
CC libvirt_qemu_la-libvirt-qemu.lo
CCLD libvirt-qemu.la
CCLD virtvboxd
/usr/bin/ld: ./.libs/libvirt-lxc.so: undefined reference to
`vir_domain_get_type'
collect2: error: ld returned 1 exit status
If I add `$(DATATYPES_SOURCES)` to `libvirt_lxc_la_SOURCES` in
`src/Makefile.am`, then the compilation is successful but virsh tools
fail with:
$: tools/virsh --connect test:///default list
(process:1086311): GLib-GObject-WARNING **: 00:59:47.905: cannot
register existing type 'virDomain'
(process:1086311): GLib-CRITICAL **: 00:59:47.905: g_once_init_leave:
assertion 'result != 0' failed
^C
I thought that by linking with libvirt.so, the `vir_domain_get_type`
symbol should be found. What am I missing?
Att
--
Rafael Fonseca