sergev / qemu

QEMU for PIC32
https://github.com/sergev/qemu/wiki
Other
29 stars 7 forks source link

Compile issue, g_mem_set_vtable is deprecated #6

Open cratuki opened 4 years ago

cratuki commented 4 years ago

During compile,

function ‘main’:
vl.c:2969:5: error: ‘g_mem_set_vtable’ is deprecated [-Werror=deprecated-declarations]
     g_mem_set_vtable(&mem_trace);
     ^~~~~~~~~~~~~~~~
In file included from /usr/include/glib-2.0/glib/glist.h:32,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from vl.c:59:
/usr/include/glib-2.0/glib/gmem.h:376:7: note: declared here
 void  g_mem_set_vtable (GMemVTable *vtable);
       ^~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [/home/cturner/opt/20200306.musicbox.cturner.ac.sergev.qemu.mips.pic32/qemu/rules.mak:57: vl.o] Error 1

Described here, https://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/%5Bqemu%5D-error-%27g_mem_set_vtable%27-is-deprecated-4175586499/

I have bypassed it by disabling the warning. This issue suggests that it is fixed in more recent qemu. (Not sure if you would be able to fast-forward easily, though) https://github.com/OpenChannelSSD/qemu-nvme/issues/2

(No further compile issues)