***************
*** 0 ****
--- 1,205 ----
+ Building a PPC NetHack 3.3 with the Metrowerks compilers
+ 
+ 
+ You must be familiar with the Metrowerks compiler and know how to construct
+ projects.  The NetHack source may come with the four pre-made projects that
+ are needed to build NetHack and the files it needs.  These four projects are
+ in :sys:mac and are MakeDefs.u, DgnComp.u, LevComp.u, and NetHack.u.  If you
+ do not have them, or wish to construct them yourself, see the section "Project
+ Contents" below.
+ 
+ 
+ 1. Move the projects MakeDefs.u, DgnComp.u, LevComp.u, and NetHack.u to the
+ top level of the NetHack tree.  If you are building your own, create each
+ project as needed, in the order given below.
+ 
+ 2. Create a folder "lib" in the top level.  This is where the files used by
+ NetHack will be deposited by MakeDefs, DgnComp, and LevComp.
+ 
+ 3. Build and run MakeDefs.
+ 
+ You will be presented with a list of options.  Initially choose them all (the
+ default).  Later you may wish to only run a few of them.  The options are
+ "odemvpqrhz", each of which makes a file:
+ 
+ 				-o creates :include:onames.h
+ 				-p creates :include:pm.h
+ 				-z creates :src:vis_tab.c
+ 				-m creates :src:monstr.c
+ 				-e creates :dat:dundeon.pdf
+ 				-v creates :lib:options
+ 				-d creates :lib:data
+ 				-r creates :lib:rumors
+ 				-h creates :lib:oracles
+ 				-q creates :lib:quest.dat
+ 
+ 
+ 4. If you are _not_ using DLB, follow these directions.  As of v3.3, DLB is ON
+ for the Mac.  Copy the following files.  You may want to change News or NHDeflts.
+ 
+ 		a. copy ':sys:mac:MacHelp' to ':lib:MacHelp'
+ 		b. copy ':sys:mac:News' to ':lib:News'
+ 		c. copy ':sys:mac:NHDeflts' to ':lib:NetHack Defaults'
+ 
+ 		d. copy	':dat:cmdhelp' to ':lib:cmdhelp'
+ 		e. copy	':dat:help' to ':lib:help'
+ 		f. copy ':dat:hh' to 'lib:hh'
+ 		g. copy	':dat:history' to ':lib:history'
+ 		h. copy	':dat:license' to ':lib:license'
+ 		i. copy	':dat:opthelp' to ':lib:opthelp'
+ 		j. copy	':dat:wizhelp' to ':lib:wizhelp'
+ 
+ 5. Create an empty file, ':lib:record'
+ 
+ 6. Build and run DgnComp.
+ 		This will create a file "dungeon" in the lib directory.
+ 
+ 7. Build and run LevComp.
+ 		This will build the level files (*.lev) in the lib directory.
+ 
+ 8. Build NetHack.
+ 		Move NetHack in the lib directory.
+ 
+ 
+ ------------------------
+ 
+ 
+ Building NetHack with MetroWerks IDE 1.x (DR7-DR10, DR11 was never used)
+ 
+ 
+ To build NetHack, you will need to create four projects at the top level of
+ the NetHack directory tree.  These four projects are MakeDefs.u, DgnComp.u,
+ LevComp.u, and NetHack.u.  The projects don't have to end in ".u", but you
+ should append some form of ".XXX" to the end of the project's name to
+ distinguish the project from the executable that it produces.  The files
+ and libraries to include in these projects are listed in the "Project
+ Contents" section below.  You must create and run Makedefs before creating
+ NetHack because MakeDefs will create files used by NetHack.
+ 
+ Use the MacOS C/C++ template for each of the projects.  The libraries included
+ will be overkill for all the projects (e.g. the C++ libraries are not needed).
+ Add the .c and resource files as indicated below.  Unless otherwise noted, the
+ projects can use the default preferences:
+ 
+ 	Font
+ 		The tabbing on all non-mac files is 8.  All mac files have a
+ 			tab of 4.
+ 	PPC Processor
+ 		All projects must have the same alignment to build a consistent
+ 			NetHack.  To share save files with 68K, the alignments
+ 			must match for their projects, as well.
+ 		Turn on Global Optimization (official version is compiled
+ 			with level 1).  If you don't turn it on, some files may
+ 			not compile because of register overflow.  [NetHack
+ 			only]
+ 	PPC Project
+ 		Set name to <MakeDefs, LevComp DgnComp, NetHack>
+ 		Other settings [NetHack only]
+ 			creator:			nh31
+ 			preferred heap size:2500
+ 			minimum heap size:	2000
+ 			stack size:			128		[PPC only]
+ 
+ 
+ The SIOUX library may be replaced with console.stubs.c for the NetHack
+ project.
+ 
+ NOTE: As NetHack 3.3, you must turn off OLDROUTINENAMES -- so you can't use
+ the default pre-compiled header.  You should either remove it from the
+ preferences or insert another precompiled header that has this define off.
+ 
+ 
+ ------------------------
+ 
+ 
+ Building NetHack with MetroWerks IDE 2.0.
+ 
+ This is for building a PowerPC version only.  This doesn't take advantage
+ of the IDE's subprojects.  These will be investigated later.
+ 
+ 
+ MakeDefs.u, DgnComp.u, LevComp.u:  Select ANSI C Console PPC.
+ 	Settings:
+ 		PPC Target
+ 			+ Change File Name to MakeDefs, DgnComp, or LevComp respectively.
+ 		C/C++ Language
+ 			+ Turn off ANSI strict, ANSI Keywords Only, Expand Trigraphs
+ 		PPC Processor
+ 			+ Turn on global optimization (at least to level 1)
+ 
+ NetHack.u: Basic ToolBox PPC
+ 		PPC Target
+ 			+ Change File Name to NetHack.  Other settings
+ 				creator:			nh31
+ 				preferred heap size:2500
+ 				minimum heap size:	2000
+ 				stack size:			128		[PPC only]
+ 		C/C++ Language
+ 			+ Options ANSI strict, ANSI Keywords Only, Expand Trigraphs
+ 			  are already turned off, so you don't have to do anything.
+ 		PPC Processor
+ 			+ Turn on global optimization (at least to level 1)
+ 
+ 
+ ------------------------
+ 
+ 
+ Project Contents:
+ 
+ MakeDefs.u should contain the following source files:
+ 
+ 	src
+ 		objects.c
+ 		monst.c
+ 	util
+ 		makedefs.c
+ 
+ 
+ DgnComp.u should contain the following source files:
+ 
+ 	src
+ 		alloc.c
+ 	sys:share
+ 		dgn_lex.c
+ 		dgn_yacc.c
+ 	util
+ 		dgn_main.c
+ 		panic.c
+ 
+ 
+ LevComp.u should contain the following source files:
+ 
+ 	src
+ 		alloc.c
+ 		decl.c
+ 		drawing.c
+ 		monst.c
+ 		objects.c
+ 	sys:mac
+ 		macerrs.c
+ 		macfile.c
+ 	sys:share
+ 		lev_lex.c
+ 		lev_yacc.c
+ 	util
+ 		lev_main.c
+ 		panic.c
+ 	
+ 
+ NetHack.u should contain the following source files:
+ 
+ 	src
+ 		*.c			[can do an add all]
+ 	sys:mac
+ 		*.c	except mrecover.c
+ 		NetHack.rsrc
+ 		Sound.rsrc	[if you wish to have a few, crude sounds]
+ 		Files.r		[if you use DLB (on by default)]
+ 	sys:share
+ 		random.c
+ 	win:tty
+ 		*.c			[can do an add all - termcap.c is not needed, but will compile to nothing]
+ 
+ 	Note: src:monstr.c and src:vis_tab.c are created by MakeDefs -m and -s
+ 	respectively.
+ 
