update config.h
Some reformatting (replacing tabs with spaces), but mostly updating some of the comments, particularly about SYSCF. Shouldn't GENERIC_USERNAMES be controllable via SYSCF?
This commit is contained in:
247
include/config.h
247
include/config.h
@@ -1,17 +1,16 @@
|
||||
/* NetHack 3.6 config.h $NHDT-Date: 1433279371 2015/06/02 21:09:31 $ $NHDT-Branch: status_hilite $:$NHDT-Revision: 1.89 $ */
|
||||
/* NetHack 3.6 config.h $NHDT-Date: 1447728911 2015/11/17 02:55:11 $ $NHDT-Branch: master $:$NHDT-Revision: 1.91 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
|
||||
#ifndef CONFIG_H /* make sure the compiler does not see the typedefs twice \
|
||||
*/
|
||||
#ifndef CONFIG_H /* make sure the compiler does not see the typedefs twice */
|
||||
#define CONFIG_H
|
||||
|
||||
/*
|
||||
* Section 1: Operating and window systems selection.
|
||||
* Select the version of the OS you are using.
|
||||
* For "UNIX" select BSD, ULTRIX, SYSV, or HPUX in unixconf.h.
|
||||
* A "VMS" option is not needed since the VMS C-compilers
|
||||
* provide it (no need to change sec#1, vmsconf.h handles it).
|
||||
* Section 1: Operating and window systems selection.
|
||||
* Select the version of the OS you are using.
|
||||
* For "UNIX" select BSD, ULTRIX, SYSV, or HPUX in unixconf.h.
|
||||
* A "VMS" option is not needed since the VMS C-compilers
|
||||
* provide it (no need to change sec#1, vmsconf.h handles it).
|
||||
*/
|
||||
|
||||
#define UNIX /* delete if no fork(), exec() available */
|
||||
@@ -53,7 +52,7 @@
|
||||
* Define the default window system. This should be one that is compiled
|
||||
* into your system (see defines above). Known window systems are:
|
||||
*
|
||||
* tty, X11, mac, amii, BeOS, Qt, Gem, Gnome
|
||||
* tty, X11, mac, amii, BeOS, Qt, Gem, Gnome
|
||||
*/
|
||||
|
||||
/* MAC also means MAC windows */
|
||||
@@ -136,40 +135,56 @@
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Section 2: Some global parameters and filenames.
|
||||
* Commenting out WIZARD, LOGFILE, NEWS or PANICLOG removes that
|
||||
* feature from the game; otherwise set the appropriate wizard
|
||||
* name. LOGFILE, NEWS and PANICLOG refer to files in the
|
||||
* playground.
|
||||
* Section 2: Some global parameters and filenames.
|
||||
*
|
||||
* If SYSCF is defined, the following configuration info is
|
||||
* available in a global config space, with the compiled-in
|
||||
* entries as defaults:
|
||||
* WIZARDS (a value of * allows anyone to be wizard)
|
||||
* (this does NOT default to compiled-in value)
|
||||
* MAXPLAYERS (see MAX_NR_OF_PLAYERS above and nethack.sh)
|
||||
* SUPPORT (how to get local support)(no default)
|
||||
* RECOVER (how to recover a game at your site)(no
|
||||
*default)
|
||||
* SHELLERS (who can use !, syntax as WIZARDS)
|
||||
* for the record file (see topten.c):
|
||||
* PERSMAX (max entries for one person)
|
||||
* ENTRYMAX (max entries in the record file)
|
||||
* POINTSMIN (min points to get an entry)
|
||||
* PERS_IS_UID (0 or 1 - person is name or (numeric) userid)
|
||||
* SEDUCE (0 or 1 - runtime disable/enable SEDUCE
|
||||
*option)
|
||||
* LOGFILE, XLOGFILE, NEWS and PANICLOG refer to files in
|
||||
* the playground directory. Commenting out LOGFILE, XLOGFILE,
|
||||
* NEWS or PANICLOG removes that feature from the game.
|
||||
*
|
||||
* The following options select how the config space is stored:
|
||||
* SYSCF_FILE in the named file
|
||||
* Building with debugging features enabled is now unconditional;
|
||||
* the old WIZARD setting for that has been eliminated.
|
||||
* If SYSCF is enabled, WIZARD_NAME will be overridden at
|
||||
* runtime by the SYSCF WIZARDS value.
|
||||
*
|
||||
* The following options pertain to crash reporting:
|
||||
* GREPPATH (the path to the system grep(1) utility)
|
||||
* GDBPATH (the path to the system gdb(1) program)
|
||||
* SYSCF: (not supported by all ports)
|
||||
* If SYSCF is defined, the following configuration info is
|
||||
* available in a global config space, with the compiled-in
|
||||
* entries as defaults:
|
||||
* WIZARDS (a space-separated list of usernames of users who
|
||||
* can run the game in debug mode, aka wizard mode;
|
||||
* a value of * allows anyone to debug;
|
||||
* this does NOT default to compiled-in value)
|
||||
* EXPLORERS (who can use explore mode, aka discover mode)
|
||||
* SHELLERS (who can use ! to execute a shell subprocess)
|
||||
* MAXPLAYERS (see MAX_NR_OF_PLAYERS below and nethack.sh)
|
||||
* SUPPORT (how to get local support) [no default]
|
||||
* RECOVER (how to recover a game at your site) [no default]
|
||||
* For the record file (see topten.c):
|
||||
* PERSMAX (max entries for one person)
|
||||
* ENTRYMAX (max entries in the record file)
|
||||
* POINTSMIN (min points to get an entry)
|
||||
* PERS_IS_UID (0 or 1 - person is name or (numeric) userid)
|
||||
* Can force incubi/succubi behavior to be toned down to nymph-like:
|
||||
* SEDUCE (0 or 1 - runtime disable/enable SEDUCE option)
|
||||
* The following options pertain to crash reporting:
|
||||
* GREPPATH (the path to the system grep(1) utility)
|
||||
* GDBPATH (the path to the system gdb(1) program)
|
||||
* Regular nethack options can also be specified in order to
|
||||
* provide system-wide default values local to your system:
|
||||
* OPTIONS (same as in users' .nethackrc or defaults.nh)
|
||||
*
|
||||
* In the future there may be other ways to supply SYSCF
|
||||
* information (Windows registry, Apple resource forks, etc)
|
||||
* but at present the only supported method is via a text file.
|
||||
* If the program is built with SYSCF enabled, the file *must*
|
||||
* exist and be readable, otherwise the game will complain and
|
||||
* refuse to start.
|
||||
* SYSCF_FILE: file containing the SYSCF options shown above;
|
||||
* default is 'sysconf' in nethack's playground.
|
||||
*/
|
||||
|
||||
#ifndef WIZARD_NAME /* allow for compile-time or Makefile changes */
|
||||
#define WIZARD_NAME "wizard"
|
||||
#define WIZARD_NAME "wizard" /* value is ignored if SYSCF is enabled */
|
||||
#endif
|
||||
|
||||
#ifndef SYSCF
|
||||
@@ -184,11 +199,20 @@
|
||||
#define GREPPATH "/bin/grep"
|
||||
#endif
|
||||
|
||||
#define LOGFILE "logfile" /* larger file for debugging purposes */
|
||||
/* note: "larger" is in comparison with 'record', the high-scores file
|
||||
(whose name can be overridden via #define in global.h if desired) */
|
||||
#define LOGFILE "logfile" /* larger file for debugging purposes */
|
||||
#define XLOGFILE "xlogfile" /* even larger logfile */
|
||||
#define NEWS "news" /* the file containing the latest hack news */
|
||||
#define NEWS "news" /* the file containing the latest hack news */
|
||||
#define PANICLOG "paniclog" /* log of panic and impossible events */
|
||||
|
||||
/*
|
||||
* PERSMAX, POINTSMIN, ENTRYMAX, PERS_IS_UID:
|
||||
* These control the contents of 'record', the high-scores file.
|
||||
* They used to be located in topten.c rather than config.h, and
|
||||
* their values can be overridden at runtime (to increase ENTRYMAX, the
|
||||
* maximum number of scores to keep, for example) if SYSCF is enabled.
|
||||
*/
|
||||
#ifndef PERSMAX
|
||||
#define PERSMAX 3 /* entries per name/uid per char. allowed */
|
||||
#endif
|
||||
@@ -207,20 +231,20 @@
|
||||
#endif
|
||||
|
||||
/*
|
||||
* If COMPRESS is defined, it should contain the full path name of your
|
||||
* 'compress' program.
|
||||
* If COMPRESS is defined, it should contain the full path name of your
|
||||
* 'compress' program.
|
||||
*
|
||||
* If you define COMPRESS, you must also define COMPRESS_EXTENSION
|
||||
* as the extension your compressor appends to filenames after
|
||||
* compression. Currently, only UNIX fully implements
|
||||
* COMPRESS; other ports should be able to uncompress save files a
|
||||
* la unixmain.c if so inclined.
|
||||
* If you define COMPRESS, you must also define COMPRESS_EXTENSION
|
||||
* as the extension your compressor appends to filenames after
|
||||
* compression. Currently, only UNIX fully implements
|
||||
* COMPRESS; other ports should be able to uncompress save files a
|
||||
* la unixmain.c if so inclined.
|
||||
*
|
||||
* Defining ZLIB_COMP builds in support for zlib compression. If you
|
||||
* define ZLIB_COMP, you must link with a zlib library. Not all ports
|
||||
* support ZLIB_COMP.
|
||||
* Defining ZLIB_COMP builds in support for zlib compression. If you
|
||||
* define ZLIB_COMP, you must link with a zlib library. Not all ports
|
||||
* support ZLIB_COMP.
|
||||
*
|
||||
* COMPRESS and ZLIB_COMP are mutually exclusive.
|
||||
* COMPRESS and ZLIB_COMP are mutually exclusive.
|
||||
*
|
||||
*/
|
||||
|
||||
@@ -234,52 +258,52 @@
|
||||
#endif
|
||||
|
||||
#ifndef COMPRESS
|
||||
/* # define ZLIB_COMP */ /* ZLIB for compression */
|
||||
/* # define ZLIB_COMP */ /* ZLIB for compression */
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Internal Compression Options
|
||||
* Internal Compression Options
|
||||
*
|
||||
* Internal compression options RLECOMP and ZEROCOMP alter the data
|
||||
* that gets written to the save file by NetHack, in contrast
|
||||
* to COMPRESS or ZLIB_COMP which compress the entire file after
|
||||
* the NetHack data is written out.
|
||||
* Internal compression options RLECOMP and ZEROCOMP alter the data
|
||||
* that gets written to the save file by NetHack, in contrast
|
||||
* to COMPRESS or ZLIB_COMP which compress the entire file after
|
||||
* the NetHack data is written out.
|
||||
*
|
||||
* Defining RLECOMP builds in support for internal run-length
|
||||
* compression of level structures. If RLECOMP support is included
|
||||
* it can be toggled on/off at runtime via the config file option
|
||||
* rlecomp.
|
||||
* Defining RLECOMP builds in support for internal run-length
|
||||
* compression of level structures. If RLECOMP support is included
|
||||
* it can be toggled on/off at runtime via the config file option
|
||||
* rlecomp.
|
||||
*
|
||||
* Defining ZEROCOMP builds in support for internal zero-comp
|
||||
* compression of data. If ZEROCOMP support is included it can still
|
||||
* be toggled on/off at runtime via the config file option zerocomp.
|
||||
* Defining ZEROCOMP builds in support for internal zero-comp
|
||||
* compression of data. If ZEROCOMP support is included it can still
|
||||
* be toggled on/off at runtime via the config file option zerocomp.
|
||||
*
|
||||
* RLECOMP and ZEROCOMP support can be included even if
|
||||
* COMPRESS or ZLIB_COMP support is included. One reason for doing
|
||||
* so would be to provide savefile read compatibility with a savefile
|
||||
* where those options were in effect. With RLECOMP and/or ZEROCOMP
|
||||
* defined, NetHack can read an rlecomp or zerocomp savefile in, yet
|
||||
* re-save without them.
|
||||
* RLECOMP and ZEROCOMP support can be included even if
|
||||
* COMPRESS or ZLIB_COMP support is included. One reason for doing
|
||||
* so would be to provide savefile read compatibility with a savefile
|
||||
* where those options were in effect. With RLECOMP and/or ZEROCOMP
|
||||
* defined, NetHack can read an rlecomp or zerocomp savefile in, yet
|
||||
* re-save without them.
|
||||
*
|
||||
* Using any compression option will create smaller bones/level/save
|
||||
* files at the cost of additional code and time.
|
||||
* Using any compression option will create smaller bones/level/save
|
||||
* files at the cost of additional code and time.
|
||||
*/
|
||||
|
||||
/* # define INTERNAL_COMP */ /* defines both ZEROCOMP and RLECOMP */
|
||||
/* # define ZEROCOMP */ /* Support ZEROCOMP compression */
|
||||
/* # define RLECOMP */ /* Support RLECOMP compression */
|
||||
/* # define INTERNAL_COMP */ /* defines both ZEROCOMP and RLECOMP */
|
||||
/* # define ZEROCOMP */ /* Support ZEROCOMP compression */
|
||||
/* # define RLECOMP */ /* Support RLECOMP compression */
|
||||
|
||||
/*
|
||||
* Data librarian. Defining DLB places most of the support files into
|
||||
* a tar-like file, thus making a neater installation. See *conf.h
|
||||
* for detailed configuration.
|
||||
* Data librarian. Defining DLB places most of the support files into
|
||||
* a tar-like file, thus making a neater installation. See *conf.h
|
||||
* for detailed configuration.
|
||||
*/
|
||||
/* #define DLB */ /* not supported on all platforms */
|
||||
|
||||
/*
|
||||
* Defining INSURANCE slows down level changes, but allows games that
|
||||
* died due to program or system crashes to be resumed from the point
|
||||
* of the last level change, after running a utility program.
|
||||
* Defining INSURANCE slows down level changes, but allows games that
|
||||
* died due to program or system crashes to be resumed from the point
|
||||
* of the last level change, after running a utility program.
|
||||
*/
|
||||
#define INSURANCE /* allow crashed game recovery */
|
||||
|
||||
@@ -299,7 +323,7 @@
|
||||
/*
|
||||
* Some system administrators are stupid enough to make Hack suid root
|
||||
* or suid daemon, where daemon has other powers besides that of reading or
|
||||
* writing Hack files. In such cases one should be careful with chdir's
|
||||
* writing Hack files. In such cases one should be careful with chdir's
|
||||
* since the user might create files in a directory of his choice.
|
||||
* Of course SECURE is meaningful only if HACKDIR is defined.
|
||||
*/
|
||||
@@ -313,15 +337,15 @@
|
||||
*/
|
||||
#endif /* CHDIR */
|
||||
|
||||
/* If GENERIC_USERNAMES is defined, and the user name is found
|
||||
* in that list, prompt for username instead.
|
||||
/* If GENERIC_USERNAMES is defined, and the player's username is found
|
||||
* in the list, prompt for character name instead of using username.
|
||||
* A public server should probably disable this. */
|
||||
#define GENERIC_USERNAMES "play player game games nethack nethacker"
|
||||
|
||||
/*
|
||||
* Section 3: Definitions that may vary with system type.
|
||||
* For example, both schar and uchar should be short ints on
|
||||
* the AT&T 3B2/3B5/etc. family.
|
||||
* Section 3: Definitions that may vary with system type.
|
||||
* For example, both schar and uchar should be short ints on
|
||||
* the AT&T 3B2/3B5/etc. family.
|
||||
*/
|
||||
|
||||
/*
|
||||
@@ -341,13 +365,11 @@
|
||||
#include "tradstdc.h"
|
||||
|
||||
/*
|
||||
* type schar: small signed integers (8 bits suffice) (eg. TOS)
|
||||
*
|
||||
* typedef char schar;
|
||||
*
|
||||
* will do when you have signed characters; otherwise use
|
||||
*
|
||||
* typedef short int schar;
|
||||
* type schar:
|
||||
* small signed integers (8 bits suffice) (eg. TOS)
|
||||
* typedef char schar;
|
||||
* will do when you have signed characters; otherwise use
|
||||
* typedef short int schar;
|
||||
*/
|
||||
#ifdef AZTEC
|
||||
#define schar char
|
||||
@@ -356,14 +378,11 @@ typedef signed char schar;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* type uchar: small unsigned integers (8 bits suffice - but 7 bits do not)
|
||||
*
|
||||
* typedef unsigned char uchar;
|
||||
*
|
||||
* will be satisfactory if you have an "unsigned char" type;
|
||||
* otherwise use
|
||||
*
|
||||
* typedef unsigned short int uchar;
|
||||
* type uchar:
|
||||
* small unsigned integers (8 bits suffice - but 7 bits do not)
|
||||
* typedef unsigned char uchar;
|
||||
* will be satisfactory if you have an "unsigned char" type; otherwise use
|
||||
* typedef unsigned short int uchar;
|
||||
*/
|
||||
#ifndef _AIX32 /* identical typedef in system file causes trouble */
|
||||
typedef unsigned char uchar;
|
||||
@@ -400,7 +419,6 @@ typedef unsigned char uchar;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#if !defined(MAC)
|
||||
#if !defined(NOCLIPPING)
|
||||
#define CLIPPING /* allow smaller screens -- ERS */
|
||||
@@ -409,7 +427,6 @@ typedef unsigned char uchar;
|
||||
|
||||
#define DOAGAIN '\001' /* ^A, the "redo" key used in cmd.c and getline.c */
|
||||
|
||||
|
||||
/*
|
||||
* Section 4: EXPERIMENTAL STUFF
|
||||
*
|
||||
@@ -418,13 +435,23 @@ typedef unsigned char uchar;
|
||||
* bugs left here.
|
||||
*/
|
||||
|
||||
/* #define STATUS_VIA_WINDOWPORT */ /* re-work of the status line updating process */
|
||||
/* #define STATUS_HILITES */ /* support hilites of status fields */
|
||||
/* #define WINCHAIN*/ /* stacked window systems */
|
||||
/* #define SCORE_ON_BOTL */ /* show estimated score on status line */
|
||||
#define FREE_ALL_MEMORY /* free all memory at exit */
|
||||
/* #define DEBUG_MIGRATING_MONS */ /* add a wizard-mode command to help debug
|
||||
migrating monsters */
|
||||
/* #define STATUS_VIA_WINDOWPORT */ /* re-work of the status line
|
||||
updating process */
|
||||
/* #define STATUS_HILITES */ /* support hilites of status fields */
|
||||
|
||||
/* #define WINCHAIN */ /* stacked window systems */
|
||||
|
||||
/* #define DEBUG_MIGRATING_MONS */ /* add a wizard-mode command to help debug
|
||||
migrating monsters */
|
||||
|
||||
/* SCORE_ON_BOTL is neither experimental nor inadequately tested,
|
||||
but doesn't seem to fit in any other section... */
|
||||
/* #define SCORE_ON_BOTL */ /* enable the 'showscore' option to
|
||||
show estimated score on status line */
|
||||
|
||||
/* FREE_ALL_MEMORY is neither experimental nor inadequately tested,
|
||||
but it isn't necessary for successful operation of the program */
|
||||
#define FREE_ALL_MEMORY /* free all memory at exit */
|
||||
|
||||
/* End of Section 4 */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user