From e2ea9558812c16291a03f3aeb636e6d7e997fa80 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 19 Jul 2007 15:37:54 +0000 Subject: [PATCH] Thu Jul 19 16:35:00 BST 2007 Richard W.M. Jones * configure.in, src/xen_internal.c: Newer Xen uses . Added detection code for this in configure.in. --- ChangeLog | 6 ++++++ configure.in | 22 ++++++++++++++++++++++ src/xen_internal.c | 8 ++++++++ 3 files changed, 36 insertions(+) diff --git a/ChangeLog b/ChangeLog index 6476171e78..884f4699b5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Thu Jul 19 16:35:00 BST 2007 Richard W.M. Jones + + * configure.in, src/xen_internal.c: Newer Xen uses + . Added detection code for this in + configure.in. + Thu Jul 19 15:38:44 CEST 2007 Daniel Veillard * src/xen_internal.c: rewrite of range check in credit scheduler diff --git a/configure.in b/configure.in index 7ceebe1fe4..78a772c3c4 100644 --- a/configure.in +++ b/configure.in @@ -212,6 +212,28 @@ else if test "$WITH_XEN" != "0" ; then LIBVIRT_FEATURES="$LIBVIRT_FEATURES -DWITH_XEN" fi + + AC_CHECK_HEADERS(xen/xen.h xen/version.h xen/dom0_ops.h,,[ + AC_MSG_ERROR([Cannot find standard Xen headers. Is xen-devel installed?]) + ], +[#include +#include +]) + + dnl Search for the location of . + AC_CHECK_HEADERS(xen/sys/privcmd.h,,[ + AC_CHECK_HEADERS(xen/linux/privcmd.h,,[ + AC_MSG_ERROR([Cannot find header file or . Is xen-devel installed?]) + ], +[#include +#include +#include +]) + ], +[#include +#include +#include +]) fi dnl diff --git a/src/xen_internal.c b/src/xen_internal.c index f3bbf812bb..94c1dc2a75 100644 --- a/src/xen_internal.c +++ b/src/xen_internal.c @@ -10,6 +10,8 @@ #ifdef WITH_XEN +#include "config.h" + #include #include /* required for uint8_t, uint32_t, etc ... */ @@ -30,7 +32,13 @@ #include #include #include +#ifdef HAVE_XEN_LINUX_PRIVCMD_H #include +#else +#ifdef HAVE_XEN_SYS_PRIVCMD_H +#include +#endif +#endif /* required for shutdown flags */ #include -- GitLab