In order to build hmp-commands.hx once we need to stop using device target-specific check. Use the generic pattern to make the command available on all targets, providing a stub with kind error message when the feature is not available. Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/kvm/xen-stubs.c | 12 ++++++++++++ hmp-commands.hx | 2 -- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/hw/i386/kvm/xen-stubs.c b/hw/i386/kvm/xen-stubs.c index ce73119ee7a..bf6ac28bef4 100644 --- a/hw/i386/kvm/xen-stubs.c +++ b/hw/i386/kvm/xen-stubs.c @@ -12,6 +12,8 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "monitor/monitor.h" +#include "monitor/hmp.h" #include "xen_evtchn.h" #include "xen_primary_console.h" @@ -37,3 +39,13 @@ void xen_primary_console_create(void) void xen_primary_console_set_be_port(uint16_t port) { } + +void hmp_xen_event_list(Monitor *mon, const QDict *qdict) +{ + monitor_printf(mon, "XEN emulation is not available in this QEMU\n"); +} + +void hmp_xen_event_inject(Monitor *mon, const QDict *qdict) +{ + monitor_printf(mon, "XEN emulation is not available in this QEMU\n"); +} diff --git a/hmp-commands.hx b/hmp-commands.hx index 5cc4788f12d..06d7b17bf25 100644 --- a/hmp-commands.hx +++ b/hmp-commands.hx @@ -1839,7 +1839,6 @@ SRST ERST #endif -#if defined(CONFIG_XEN_EMU) { .name = "xen-event-inject", .args_type = "port:i", @@ -1866,4 +1865,3 @@ SRST ``xen-event-list`` List event channels in the guest ERST -#endif -- 2.53.0