From: Jan Beulich Date: Mon, 13 Aug 2012 17:08:37 +0000 (+0100) Subject: libxl: fix build for gcc prior to 4.3 X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~8057 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=1b7378d1b6289cc417c35bf1675d188390534643;p=xen.git libxl: fix build for gcc prior to 4.3 So far all we (explicitly) require is gcc 3.4 or better, so we shouldn't be unconditionally using features supported only by much newer versions. Signed-off-by: Jan Beulich Acked-by: Ian Jackson Committed-by: Ian Jackson --- diff --git a/tools/libxl/libxl_internal.h b/tools/libxl/libxl_internal.h index cf5d9e92df..7c3b179738 100644 --- a/tools/libxl/libxl_internal.h +++ b/tools/libxl/libxl_internal.h @@ -55,8 +55,10 @@ #ifdef LIBXL_H # error libxl.h should be included via libxl_internal.h, not separately #endif -#define LIBXL_EXTERNAL_CALLERS_ONLY \ +#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3) +# define LIBXL_EXTERNAL_CALLERS_ONLY \ __attribute__((warning("may not be called from within libxl"))) +#endif #include "libxl.h" #include "_paths.h"