From 81b7b1e21d5da37faef1dbb5404f3adae7e68ac2 Mon Sep 17 00:00:00 2001 From: David CARLIER Date: Mon, 13 Jul 2020 14:36:10 +0100 Subject: util/compatfd.c: Only include if CONFIG_SIGNALFD util/compatfd.c includes so that the CONFIG_SIGNALFD code can use SYS_signalfd. Guard the #include with CONFIG_SIGNALFD to avoid portability issues on hosts like Haiku which do not provide that header file. Signed-off-by: David Carlier Reviewed-by: Peter Maydell Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell Message-id: 20200703145614.16684-8-peter.maydell@linaro.org [PMM: Expanded commit message] Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell --- util/compatfd.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'util') diff --git a/util/compatfd.c b/util/compatfd.c index c296f55d14..ee47dd8089 100644 --- a/util/compatfd.c +++ b/util/compatfd.c @@ -16,7 +16,9 @@ #include "qemu/osdep.h" #include "qemu/thread.h" +#if defined(CONFIG_SIGNALFD) #include +#endif struct sigfd_compat_info { -- cgit v1.2.3