Subject: Re: trouble compiling a kernel
To: None <winter@jurai.net>
From: Greg Earle <earle@isolar.Tujunga.CA.US>
List: port-sparc
Date: 09/03/1997 18:06:42
>> I'm having trouble compiling a kernel for NetBSD/sparc 1.2.1 release...
>> 
>> compile of /sys/arch/sparc/dev/bwtwo.c dies with 
>> 
>> bwtwo.c:328: structure has no member named `sc_ovtype'
>> bwtwo.c:328: BWO_NONE undeclared (first use this function)
>> 
>> This block of code is enclosed within an #ifdef RASTERCONSOLE - what's not
>> getting included that I need?
>> 
>> Also, this box is an IPC (bwtwo is onboard), but my console is hooked up
>> to a cgsix in SBus slot 1.  Do I need bwtwo support at all?
> 
> If I had a copy of the original bwtwo.c, I"d do context diff but 
> line 327 may be changed to :
> 
> #if defined(RASTERCONSOLE) && defined(SUN4)
> 
> to compile a sparc kernel for SUN4C without SUN4 defined.
> 
> I noticed this a few months ago but forgot about it.

[Sorry, I'm about 1100 e-mails backed up at the moment ... :-( ]

This is a more official-ish fix that I got from pk, I think:

	- Greg

*** /usr/src/1.2.1/sys/arch/sparc/dev/bwtwo.c-1.2.1	Wed Dec 11 02:57:26 1996
--- /usr/src/1.2.1/sys/arch/sparc/dev/bwtwo.c	Fri Apr 11 14:23:42 1997
***************
*** 1,2 ****
! /*	$NetBSD: bwtwo.c,v 1.26.4.1 1996/12/10 19:24:43 mycroft Exp $ */
  
--- 1,2 ----
! /*	$NetBSD: bwtwo.c,v 1.26.4.2 1997/03/02 21:52:11 pk Exp $ */
  
***************
*** 327,329 ****
  #ifdef RASTERCONSOLE
! 		if (sc->sc_ovtype == BWO_NONE)
  			fbrcons_init(fb);
--- 327,337 ----
  #ifdef RASTERCONSOLE
! #if defined(SUN4)
! 		/*
! 		 * XXX rcons doesn't seem to work properly on the overlay
! 		 * XXX plane.  This is a temporary kludge until someone
! 		 * XXX fixes it.
! 		 */
! 		if ((fb->fb_flags & FB_PFOUR) == 0 ||
! 		    (sc->sc_ovtype == BWO_NONE))
! #endif
  			fbrcons_init(fb);