Hi!
There''s a include path mistake when trying to build
tools/libxc on OpenBSD:
gcc -O2 -fomit-frame-pointer -m32 -march=i686 -DNDEBUG -std=gnu99 -Wall
-Wstrict-prototypes -Wno-unused-value -D__XEN_TOOLS__ -Werror
-fno-strict-aliasing -I. -Wp,-MD,.xc_core.o.d -c -o xc_core.o xc_core.c
In file included from xc_private.h:18,
from xg_private.h:16,
from xc_core.c:1:
xen/privcmd.h:36:23: asm/types.h: No such file or directory
gcc tries to use /usr/include/asm/types.h, which only exists on Linux (and
therefore works on Linux).
The attached patch tells gcc to use $(XEN_ROOT)/xen/include/asm/types.h.
I think, this was originally intended, right?
ATTENTION: The patch uncovers several header issues:
gcc -O2 -fomit-frame-pointer -m32 -march=i686 -DNDEBUG -std=gnu99 -Wall
-Wstrict-prototypes -Wno-unused-value -D__XEN_TOOLS__ -Werror
-fno-strict-aliasing -I. -I../../xen/include -Wp,-MD,.xc_core.o.d -c -o
xc_core.o xc_core.c
In file included from ../../xen/include/xen/config.h:10,
from ../../xen/include/asm/types.h:6,
from xen/privcmd.h:36,
from xc_private.h:18,
from xg_private.h:16,
from xc_core.c:1:
../../xen/include/asm/config.h:278:1: "HYPERVISOR_VIRT_START"
redefined
In file included from xen/xen.h:15,
from xenctrl.h:19,
from xg_private.h:14,
from xc_core.c:1:
xen/arch-x86_32.h:107:1: this is the location of the previous definition
In file included from ../../xen/include/xen/config.h:37,
from ../../xen/include/asm/types.h:6,
from xen/privcmd.h:36,
from xc_private.h:18,
from xg_private.h:16,
from xc_core.c:1:
../../xen/include/xen/compiler.h:35:1: "offsetof" redefined
In file included from xenctrl.h:17,
from xg_private.h:14,
from xc_core.c:1:
/usr/include/stddef.h:75:1: this is the location of the previous definition
In file included from xen/privcmd.h:36,
from xc_private.h:18,
from xg_private.h:16,
from xc_core.c:1:
../../xen/include/asm/types.h:43: error: conflicting types for
`paddr_t''
/usr/include/sys/types.h:124: error: previous declaration of `paddr_t''
../../xen/include/asm/types.h:53: warning: redefinition of `size_t''
/usr/include/sys/types.h:178: warning: `size_t'' previously declared
here
gmake[1]: *** [xc_core.o] Error 1
gmake[1]: Leaving directory
`/usr/src/xen-unstable-openbsd.hg/tools/libxc''
gmake: *** [build] Error 2
The patch should NOT go into -unstable, until the header issues have been
fixed. I post this patch just in case there''s someone else having build
troubles with libxc.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel