Port-xen archive

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

Re: Building Xen 4.2 on NetBSD (was Re: block-attach/detach device oddness)

On 11/30/12 8:54 AM, Roger Pau Monné wrote:
On 30/11/12 17:42, Jeff Rizzo wrote:

Well, setting that at the top-level (APPEND_INCLUDES="/usr/pkg/include
/usr/X11R7/include") doesn't work right because (apparently) bad quoting
in the top-level configure:

#!/bin/sh -e
cd tools && ./configure $@

hackbook:riz  ~/xen-4.2.0> ./configure PYTHON=/usr/pkg/bin/python2.7
APPEND_INCLUDES="/usr/pkg/include /usr/X11R7/include"
APPEND_LIB=/usr/pkg/lib --prefix=/usr/xen42
You should set those before calling configure:

# PYTHON=/usr/pkg/bin/python2.7 APPEND_INCLUDES="/usr/pkg/include
/usr/X11R7/include" APPEND_LIB=/usr/pkg/lib ./configure --prefix=/usr/xen42

At least it works this way for me (configure, haven't tried the build
with X11 packages). If this doesn't work I will probably have to look at
how pkgsrc deals with that, since I guess the pkgsrc Xen is able to
compile successfully with X11.

OK, it works better setting them before calling configure. (Another point where the wiki needs updating)

However, it doesn't actually fix the build. Looks like the APPEND_INCLUDES don't actually get passed down the the qemu build, perhaps? I got a little farther when I added -I/usr/X11R7/include by hand to CPPFLAGS in tools/qemu-xen-traditional/Makefile, but then ran up against this, so I clearly need more:

/home/riz/xen-4.2.0/tools/qemu-xen-traditional/i386-dm/helper2.c: In function 'cpu_x86_init': /home/riz/xen-4.2.0/tools/qemu-xen-traditional/i386-dm/helper2.c:160:49: error: 'HVM_PARAM_BUFIOREQ_EVTCHN' undeclared (first use in this function) /home/riz/xen-4.2.0/tools/qemu-xen-traditional/i386-dm/helper2.c:160:49: note: each undeclared identifier is reported only once for each function it appears in
gmake[4]: *** [helper2.o] Error 1

Poking around in the other files, I couldn't figure out the correct way to include the params.h file with the needed definition, but I did see that some of the other qemu files did this:

./tools/qemu-xen/xen-all.c:#ifndef HVM_PARAM_BUFIOREQ_EVTCHN
./tools/qemu-xen/xen-all.c:#define HVM_PARAM_BUFIOREQ_EVTCHN 26

...so I added the same to tools/qemu-xen-traditional/i386-dm/helper2.c.

I also had to add -I/usr/X11R7/include to SDL_CFLAGS in a couple places to get qemu to build.

Eventually, I got it to build, but it still feels kind of fragile - there's clearly more to do to fix things "right".

Now to see if it actually works.  :)


Home | Main Index | Thread Index | Old Index