Subject: Re: bochs pkgsrc snafu?
To: <>
From: David Laight <david@l8s.co.uk>
List: netbsd-help
Date: 08/21/2003 19:03:11
On Thu, Aug 21, 2003 at 10:30:56AM -0700, Harry Waddell wrote:
> On Thu, 21 Aug 2003 10:05:46 +0100
> David Laight <david@l8s.co.uk> wrote:
> 
> > On Thu, Aug 21, 2003 at 12:15:52AM -0400, Bob Bernstein wrote:
> > > I see this trying to build bochs pkgsrc:
> > 
> > > ../cpu/cpu.h:1832: macro `CPUID' used with just one arg
> > 
> > Something must be including machine/specialreg.h (which is where CPUID
> > gets its other definition).
> > 
> > The easy way to find out is to add:
> > #define CPUID
> > to the top of devices.cc and see where the compiler objects to the
> > duplicate definition.
> > 
> > My running system isn't quite current enough to reproduce the error.
> > 
> > 	David
> 
> As of a couple weeks ago, bochs wouldn't compile under current because a
> CPUID macro has been added to one of the system header files. Bochs also
> defines a macro CPUID. After doing "make patch" in pkgsrc/emulators/bochs,
> changing all instances, about 5 as I recall, of CPUID in the patches bochs
> source to BOCHSCPUID did the trick for me. I'm sure there's a more elegant
> way to do this, which is why I did not submit a patch via GNATS.

I look at two options:
1) work out why bochs is including that header file, as a 'normal'
   application it shouldn't be.
2) Patch in a #undef CPUID somewhere.

	David

-- 
David Laight: david@l8s.co.uk