Difference between revisions of "Makedefs"

From NetHackWiki
Jump to navigation Jump to search
(makedefs generates part of the source code.)
 
(commandline params)
Line 2: Line 2:
  
 
In the [[Unix]] Makefiles, makedefs is called from the Makefiles in the src and utl directories.
 
In the [[Unix]] Makefiles, makedefs is called from the Makefiles in the src and utl directories.
 +
 +
makedefs accepts the following commandline parameters:
 +
 +
* <tt>-o</tt> creates [[onames.h]]
 +
* <tt>-d</tt> creates the database
 +
* <tt>-e</tt> creates the dungeon.pdf (from dungeon.def)
 +
* <tt>-m</tt> creates [[monstr.c]]
 +
* <tt>-v</tt> creates [[date.h]] and options-file
 +
* <tt>-p</tt> creates [[pm.h]]
 +
* <tt>-q</tt> creates quest-file quest.dat from quest.txt
 +
* <tt>-r</tt> creates rumors
 +
* <tt>-h</tt> creates oracles
 +
* <tt>-z</tt> creates [[vis_tab.h]] and [[vis_tab.c]] (vision lookup tables)
  
 
[[Category:Source code]]
 
[[Category:Source code]]

Revision as of 18:03, 26 August 2006

In util/makedefs.c is the source for a program called makedefs. When you build a copy of NetHack, it uses makedefs to generate date.h, onames.h, pm.h, vis_tab.h, and vis_tab.c. This explains why those files are missing from an unbuilt copy of the source code.

In the Unix Makefiles, makedefs is called from the Makefiles in the src and utl directories.

makedefs accepts the following commandline parameters:

  • -o creates onames.h
  • -d creates the database
  • -e creates the dungeon.pdf (from dungeon.def)
  • -m creates monstr.c
  • -v creates date.h and options-file
  • -p creates pm.h
  • -q creates quest-file quest.dat from quest.txt
  • -r creates rumors
  • -h creates oracles
  • -z creates vis_tab.h and vis_tab.c (vision lookup tables)