To: xbugs@x.org
Subject: config: Add support for Sun3 running NetBSD-1.0
Cc: gwr@netbsd.org

     VERSION:

R6, public-patch-11

     CLIENT MACHINE and OPERATING SYSTEM:

Sun3 / NetBSD-1.0

     DISPLAY TYPE:

Sun bwtwo, cgtwo, cgfour

     WINDOW MANAGER:

twm (any)

     COMPILER:

native cc

     AREA:

config

     SYNOPSIS:

Add support for Sun3 running NetBSD-1.0

     DESCRIPTION:

This is an enhancement to allow the X core distribution to be
built for a Sun3 running NetBSD-1.0 (or later).

     REPEAT BY:

cd $TOP ; make World

     SAMPLE FIX:

These changes provide for definition of the preprocessor symbols:
	-Dsun3 -Dmc68000
which are required for building the core distribution and servers.
Also, untangle the arch. specific parts of NetBSD.cf a little bit.

Files affected:
 config/cf/Imake.cf
 config/cf/NetBSD.cf
 config/imake/imakemdep.h

*** config/cf/Imake.cf.save	Wed Mar 15 16:16:06 1995
--- config/cf/Imake.cf	Tue May 30 16:53:04 1995
***************
*** 1,4 ****
--- 1,5 ----
  XCOMM $XConsortium: Imake.cf,v 1.19 95/01/05 19:24:32 kaleb Exp $
+ XCOMM Sun3/NetBSD-1.0 <gwr@netbsd.org>
  /*
   * To add support for another platform:
   * 
***************
*** 62,68 ****
  #if defined(__sparc__) || defined(sparc)
  #define SparcArchitecture
  #undef sparc
! #endif
  #endif /* NetBSD */
  
  #ifdef __FreeBSD__
--- 63,73 ----
  #if defined(__sparc__) || defined(sparc)
  #define SparcArchitecture
  #undef sparc
! #endif	/* sparc */
! #if defined(__sun3__) || defined(sun3)
! #define Sun3Architecture
! #undef sun3
! #endif	/* sun3 */
  #endif /* NetBSD */
  
  #ifdef __FreeBSD__

*** config/cf/NetBSD.cf.save	Wed Mar 15 16:16:08 1995
--- config/cf/NetBSD.cf	Tue May 30 16:54:23 1995
***************
*** 1,4 ****
--- 1,5 ----
  XCOMM platform:  $XConsortium: NetBSD.cf,v 1.4 95/01/05 19:39:34 kaleb Exp $
+ XCOMM Sun3/NetBSD-1.0 <gwr@netbsd.org>
  
  #define OSName		NetBSD
  #define	OSVendor	/**/
***************
*** 50,64 ****
  #ifdef i386Architecture
  #define OptimizedCDebugFlags	-m486 -O2
  #define ServerOSDefines		XFree86ServerOSDefines -DDDXTIME
! #else
  #define OptimizedCDebugFlags	-O2
- # ifdef SparcArchitecture
- #  define ServerOSDefines	-DDDXOSINIT
- # else
- #  define ServerOSDefines	/**/
- # endif
  #endif
- #define ServerExtraDefines GccGasOption XFree86ServerDefines
  
  #define StandardDefines	-DCSRG_BASED
  #define XawI18nDefines	-DUSE_XWCHAR_STRING -DUSE_XMBTOWC
--- 53,76 ----
  #ifdef i386Architecture
  #define OptimizedCDebugFlags	-m486 -O2
  #define ServerOSDefines		XFree86ServerOSDefines -DDDXTIME
! #define ServerExtraDefines GccGasOption XFree86ServerDefines
! #endif
! 
! #ifdef	SparcArchitecture
! #define ServerOSDefines	-DDDXOSINIT
! #define ServerExtraDefines GccGasOption
! #endif
! 
! #ifdef	Sun3Architecture
! /* Note: -ansi turns off -Dmc68000 */
! #define ServerOSDefines	-DDDXOSINIT
! #define ServerExtraDefines GccGasOption -Dmc68000
! #define BootstrapCFlags -Dsun3
! #endif
! 
! #ifndef	OptimizedCDebugFlags
  #define OptimizedCDebugFlags	-O2
  #endif
  
  #define StandardDefines	-DCSRG_BASED
  #define XawI18nDefines	-DUSE_XWCHAR_STRING -DUSE_XMBTOWC
***************
*** 129,135 ****
  
  #include <bsdLib.rules>
  
! #ifdef SparcArchitecture
  #ifndef Xsun24Server
  #define Xsun24Server	NO
  #endif
--- 141,147 ----
  
  #include <bsdLib.rules>
  
! #if defined(SparcArchitecture) || defined(Sun3Architecture)
  #ifndef Xsun24Server
  #define Xsun24Server	NO
  #endif
***************
*** 139,146 ****
  #ifndef XsunMonoServer
  #define XsunMonoServer	YES
  #endif
! #ifndef UseRGBTxt
! #define UseRGBTxt	YES
  #endif
  #endif
  
--- 151,158 ----
  #ifndef XsunMonoServer
  #define XsunMonoServer	YES
  #endif
! #ifndef UseRgbTxt
! #define UseRgbTxt	YES
  #endif
  #endif
  
*** config/imake/imakemdep.h.save	Wed Mar 15 16:16:10 1995
--- config/imake/imakemdep.h	Tue May 30 17:03:52 1995
***************
*** 1,4 ****
--- 1,5 ----
  /* $XConsortium: imakemdep.h,v 1.82 95/01/12 16:27:01 kaleb Exp $ */
+ /* Sun3/NetBSD-1.0 <gwr@netbsd.org> */
  /*
  
  Copyright (c) 1993, 1994  X Consortium
***************
*** 250,262 ****
  	"-Uunix",	/* remove unix symbol so that filename unix.c okay */
  #endif
  #if defined(__386BSD__) || defined(__NetBSD__) || defined(__FreeBSD__)
  # ifdef __i386__
  	"-D__i386__",
  # endif
! # ifdef __GNUC__
! 	"-traditional"
  # endif
! #endif
  #ifdef M4330
  	"-DM4330",	/* Tektronix */
  #endif
--- 251,266 ----
  	"-Uunix",	/* remove unix symbol so that filename unix.c okay */
  #endif
  #if defined(__386BSD__) || defined(__NetBSD__) || defined(__FreeBSD__)
+ # ifdef __GNUC__
+ 	"-traditional",
+ # endif
  # ifdef __i386__
  	"-D__i386__",
  # endif
! # ifdef sun3
! 	"-Dsun3",
  # endif
! #endif	/* __XxxBSD__ */
  #ifdef M4330
  	"-DM4330",	/* Tektronix */
  #endif
