1 /* NetHack 3.6 vmsconf.h $NHDT-Date: 1555361299 2019/04/15 20:48:19 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.30 $ */
2 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
3 /*-Copyright (c) Robert Patrick Rankin, 2011. */
4 /* NetHack may be freely redistributed. See license for details. */
11 * Edit these to choose values appropriate for your site.
12 * WIZARD is the username allowed to use the debug option of nethack; no harm
13 * is done by leaving it as a username that doesn't exist at your site.
14 * HACKDIR can be overridden at run-time with the logical name HACKDIR, as in
15 * $ define hackdir disk$users:[games.nethack]
16 * Trailing NULs are present in the default values in order to make some
17 * extra room for patching longer values into an existing executable.
19 #define Local_WIZARD "NHWIZARD\0\0\0\0"
20 #define Local_HACKDIR "DISK$USERS:[GAMES.NETHACK.3_5_X.PLAY]\0\0\0\0\0\0\0\0"
23 * This section cleans up the stuff done in config.h so that it
24 * shouldn't need to be modified. It's conservative so that if
25 * config.h is actually edited, the changes won't impact us.
36 #define HACKDIR Local_HACKDIR
37 #define WIZARD_NAME Local_WIZARD
42 /* filenames require punctuation to avoid redirection via logical names */
44 #define RECORD "record;1" /* scoreboard file (retains high scores) */
46 #define LOGFILE "logfile;0" /* optional file (records all games) */
48 #define SYSCF_FILE "sysconf;0"
50 #define HLOCK "perm;1" /* an empty file used for locking purposes */
52 /* want compression--for level & save files--performed within NetHack itself
62 * If nethack.exe will be installed with privilege so that the playground
63 * won't need to be left unprotected, define SECURE to suppress a couple
64 * of file protection fixups (protection of bones files and ownership of
70 * If you use SECURE you'll need to link /noTraceback, in which case
71 * there's no point trying to get extra PANICTRACE info and this might
72 * as well be commented out. When enabled, the sysconf file controls
73 * how to handle it (note that we're hijacking the Unix GDB setting):
74 PANICTRACE_GDB=0 #behave as if PANICTRACE was disabled
75 PANICTRACE_GDB=1 #at conclusion of panic, show a call traceback and exit
76 PANICTRACE_GDB=2 #at conclusion of panic, show a call traceback and then
77 * # remain in the debugger for more interactive debugging
78 * # (not as useful as it might sound since we're normally
79 * # linked /noDebug so there's no symbol table accessible)
84 * Put the readonly data files into a single container rather than into
85 * separate files in the playground directory.
87 #define DLB /* use data librarian code */
90 * Provide menu of saved games to choose from at start.
91 * [Player needs to use ``nethack "-ugames"'' for this to work.]
96 * You may define TEXTCOLOR if your system has any terminals that recognize
97 * ANSI color sequences of the form ``<ESCAPE>[#;#m'', where the first # is
98 * a number between 40 and 47 represented background color, and the second
99 * # is a number between 30 and 37 representing the foreground color.
100 * GIGI terminals and DECterm windows on color VAXstations support these
101 * color escape sequences, as do some 3rd party terminals and many micro
104 /* #define TEXTCOLOR */
107 * If you define USE_QIO_INPUT, then you'll get raw characters from the
108 * keyboard, not unlike those of the unix version of Nethack. This will
109 * allow you to use the Escape key in normal gameplay, and the appropriate
110 * control characters in Wizard mode. It will work most like the unix
112 * It will also avoid "<interrupt>" being displayed when ^Y is pressed.
114 * Otherwise, the VMS SMG calls will be used. These calls block use of
115 * the escape key, as well as certain control keys, so gameplay is not
116 * the same, although the differences are fairly negligible. You must
117 * then use a VTxxx function key or two <escape>s to give an ESC response.
119 #define USE_QIO_INPUT /* use SYS$QIOW instead of SMG$READ_KEYSTROKE */
122 * Allow the user to decide whether to pause via timer or excess screen
123 * output for various display effects like explosions and moving objects.
125 #define TIMED_DELAY /* enable the `timed_delay' run-time option */
128 * If you define MAIL, then NetHack will capture incoming broadcast
129 * messages such as "New mail from so-and-so" and "Print job completed,"
130 * and then deliver them to the player. For mail and phone broadcasts
131 * a scroll of mail will be created, which when read will cause NetHack
132 * to prompt the player for a command to spawn in order to respond. The
133 * latter capability will not be available if SHELL is disabled below.
134 * If you undefine MAIL, broadcasts will go straight to the terminal,
135 * resulting in disruption of the screen display; use <ctrl/R> to redraw.
137 #define MAIL /* enable broadcast trapping */
140 * SHELL enables the player to 'escape' into a spawned subprocess via
141 * the '!' command. Logout or attach back to the parent to resume play.
142 * If the player attaches back to NetHack, then a subsequent escape will
143 * re-attach to the existing subprocess. Any such subprocess left over
144 * at game exit will be deleted by an exit handler.
145 * SUSPEND enables someone running NetHack in a subprocess to reconnect
146 * to the parent process with the <ctrl/Z> command; this is not very
147 * close to Unix job control, but it's better than nothing.
149 #define SHELL /* do not delete the '!' command */
150 #define SUSPEND /* don't delete the ^Z command, such as it is */
153 * Some terminals or terminal emulators send two character sequence "ESC c"
154 * when Alt+c is pressed. The altmeta run-time option allows the user to
155 * request that "ESC c" be treated as M-c, which means that if nethack sees
156 * ESC when it is waiting for a command, it will wait for another character
157 * (even if user intended that ESC to be standalone to cancel a count prefix).
159 #define ALTMETA /* support altmeta run-time option */
161 #define RANDOM /* use sys/share/random.c instead of vaxcrtl rand */
163 /* config.h defines USE_ISAAC64; we'll use it on Alpha or IA64 but not VAX;
164 it overrides RANDOM */
165 #if (defined(VAX) || defined(vax) || defined(__vax)) && defined(USE_ISAAC64)
169 #define FCMASK 0660 /* file creation mask */
172 * The remainder of the file should not need to be changed.
175 /* data librarian defs */
177 #define DLBFILE "nh-data.dlb"
179 * Since we can do without case insensitive filename comparison,
180 * avoid enabling it because that requires compiling and linking
181 * src/hacklib into util/dlb_main.
183 /* # define FILENAME_CMP strcmpi */ /* case insensitive */
186 #if defined(VAXC) && !defined(ANCIENT_VAXC)
196 #define STRICT_REF_DEF /* used in lev_main.c */
198 #ifdef STRICT_REF_DEF
199 #define DEFINE_OSPEED
203 /* bison generated foo_yacc.c might try to use alloca() */
205 #define alloca __builtin_alloca
207 #define ALLOCA_HACK /* used in util/panic.c */
211 #ifdef _DECC_V4_SOURCE
212 /* <types.h> excludes some necessary typedefs when _DECC_V4_SOURCE is defined
217 typedef __pid_t pid_t;
221 typedef __uid_t uid_t;
225 typedef __gid_t gid_t;
229 typedef __mode_t mode_t;
231 #endif /* _DECC_V4_SOURCE */
234 #if 0 /* <file.h> is missing for old gcc versions; skip it to save time */
236 #else /* values needed from missing include file */
240 #define O_CREAT 0x200
241 #define O_TRUNC 0x400
244 #define tgetch vms_getchar
246 #if defined(__DECC_VER) && (__DECC_VER >= 50000000)
247 /* for cc/Standard=ANSI89, suppress notification that '$' in identifiers
248 is an extension; sys/vms/*.c needs it regardless of strict ANSI mode */
249 # pragma message disable DOLLARID
255 #define rindex strrchr
257 /* Use the high quality random number routines. */
260 # define Rand() random()
261 /* VMS V7 adds these entry points to DECC$SHR; stick with the nethack-supplied
262 code to avoid having to deal with version-specific conditionalized builds */
263 # define random nh_random
264 # define srandom nh_srandom
265 # define initstate nh_initstate
266 # define setstate nh_setstate
268 # define Rand() rand()
274 #define bcopy(s, d, n) memcpy((d), (s), (n)) /* vaxcrtl */
277 #define abort() vms_abort() /* vmsmisc.c */
278 #define creat(f, m) vms_creat(f, m) /* vmsfiles.c */
279 #define exit(sts) vms_exit(sts) /* vmsmisc.c */
280 #define getuid() vms_getuid() /* vmsunix.c */
281 #define link(f1, f2) vms_link(f1, f2) /* vmsfiles.c */
282 #define open(f, k, m) vms_open(f, k, m) /* vmsfiles.c */
283 #define fopen(f, m) vms_fopen(f, m) /* vmsfiles.c */
284 /* #define unlink(f0) vms_unlink(f0) /* vmsfiles.c */
286 #define unlink(f0) delete (f0) /* vaxcrtl */
288 #define unlink(f0) remove(f0) /* vaxcrtl, decc$shr */
290 #define C$$TRANSLATE(n) c__translate(n) /* vmsfiles.c */
292 /* VMS global names are case insensitive... */
295 #define Shk_Your vms_shk_your
297 /* avoid global symbol in Alpha/VMS V1.5 STARLET library (link trouble) */
298 #define ospeed vms_ospeed
300 /* used in several files which don't #include "extern.h" */
301 extern void FDECL(vms_exit, (int));
302 extern int FDECL(vms_open, (const char *, int, unsigned));
303 extern FILE *FDECL(vms_fopen, (const char *, const char *));
304 char *FDECL(vms_basename, (const char *)); /* vmsfiles.c */
306 #endif /* VMSCONF_H */