[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] tools/libs/guest: fix out of tree builds of libxenguest users


  • To: Juergen Gross <jgross@xxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • Date: Thu, 24 Sep 2020 21:23:58 +0100
  • Authentication-results: esa4.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
  • Cc: Ian Jackson <iwj@xxxxxxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Thu, 24 Sep 2020 20:24:09 +0000
  • Ironport-sdr: B7VWk2xeSsxvj4f/e1LuDpnX7K5nwfgh2hcZXE7L5VVb78gJYpyKLyajyWmjPo0/FvoVXUlJ8y EPOi0BX8wSNOZHu7KXZSz31i3eNtbup1f4dHA2v8fpn/cdSXlMUyBo3YGi7rCTaJK6/07xQIfY NbWT2+JQZaG/AxXc7Cyzts6IjBxIqaageRtd3VjuBwdUGo0nzJZfE5raa6OpuVzf1yN6KkKm3r Sa3SwKiKJb3febIDaRIsQ7g1gXiKA0P9/j5MQwTWkEwyAyzI5b8hYUaV45nxhPKa4HawomMorc JyQ=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 23/09/2020 06:24, Juergen Gross wrote:
> xenguest.h includes xenctrl_dom.h, which is including the Xen internal
> xen/libelf/libelf.h. This results in build failures for components
> using libxenguest when being built outside the Xen build environment.
>
> Fix that by guarding the include of xenctrl_dom.h with
> "#ifdef __XEN_TOOLS_".
>
> Fixes: 7e0165c19387 ("tools/libxc: untangle libxenctrl from libxenguest")
> Reported-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
> Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
> ---
>  tools/libs/guest/include/xenguest.h | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/tools/libs/guest/include/xenguest.h 
> b/tools/libs/guest/include/xenguest.h
> index 4643384790..5cd502f644 100644
> --- a/tools/libs/guest/include/xenguest.h
> +++ b/tools/libs/guest/include/xenguest.h
> @@ -22,7 +22,9 @@
>  #ifndef XENGUEST_H
>  #define XENGUEST_H
>  
> +#ifdef __XEN_TOOLS__
>  #include <xenctrl_dom.h>
> +#endif

I have to admit that this doesn't feel right to put into a public header.

Can't we split xenctrl_dom in half and merge the relevant subsets into
xen{ctrl,guest}.h ?

~Andrew



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.