3 * @brief 変愚時追加された基本事項のヘッダーファイル /
4 * The most basic "include" file. This file simply includes other low level header files.
10 * Choose the hardware, operating system, and compiler.
11 * Also, choose various "system level" compilation options.
12 * A lot of these definitions take effect in "h-system.h"
13 * Note that you may find it simpler to define some of these
14 * options in the "Makefile", especially any options describing
15 * what "system" is being used.
16 * no system definitions are needed for 4.3BSD, SUN OS, DG/UX
20 #ifndef INCLUDED_H_CONFIG_H
21 #define INCLUDED_H_CONFIG_H
25 * OPTION: Compile on a Macintosh (see "A-mac-h" or "A-mac-pch")
26 * Automatic for Mac MPW compilation
29 /* #define MACINTOSH */
33 * OPTION: Compile on Windows (automatic)
40 * Extract the "MAC_MPW" flag from the compiler
42 #if defined(__SC__) || defined(__MRC__)
54 /* Use the new SVGA code */
63 * OPTION: Compile on a HPUX version of UNIX
70 * OPTION: Compile on an SGI running IRIX
77 * OPTION: Compile on a Solaris machine
84 * OPTION: Compile on an ultrix/4.2BSD/Dynix/etc. version of UNIX,
85 * Do not define this if you are on any kind of SunOS.
93 * Extract the "ULTRIX" flag from the compiler
95 #if defined(ultrix) || defined(Pyramid)
102 * Extract the "ACORN" flag from the compiler
111 * Extract the "SGI" flag from the compiler
120 * Extract the "WINDOWS" flag from the compiler
122 #if defined(_Windows) || defined(__WINDOWS__) || \
123 defined(__WIN32__) || defined(WIN32) || \
124 defined(__WINNT__) || defined(__NT__)
133 * OPTION: Define "L64" if a "long" is 64-bits. See "h-types.h".
134 * The only such platform that angband is ported to is currently
135 * DEC Alpha AXP running OSF/1 (OpenVMS uses 32-bit longs).
137 #if defined(__alpha) && defined(__osf__)
144 * OPTION: set "SET_UID" if the machine is a "multi-user" machine.
145 * This option is used to verify the use of "uids" and "gids" for
146 * various "Unix" calls, and of "pids" for getting a random seed,
147 * and of the "umask()" call for various reasons, and to guess if
148 * the "kill()" function is available, and for permission to use
149 * functions to extract user names and expand "tildes" in filenames.
150 * It is also used for "locking" and "unlocking" the score file.
151 * Basically, SET_UID should *only* be set for "Unix" machines,
152 * or for the "Atari" platform which is Unix-like, apparently
154 #if !defined(MACINTOSH) && !defined(WINDOWS) && \
155 !defined(ACORN) && !defined(VM)
161 * OPTION: Set "USG" for "System V" versions of Unix
162 * This is used to choose a "lock()" function, and to choose
163 * which header files ("string.h" vs "strings.h") to include.
164 * It is also used to allow certain other options, such as options
165 * involving userid's, or multiple users on a single machine, etc.
168 # if defined(SOLARIS) || \
169 defined(HPUX) || defined(SGI)
178 * Every system seems to use its own symbol as a path separator.
179 * Default to the standard Unix slash, but attempt to change this
180 * for various other systems. Note that any system that uses the
181 * "period" as a separator (i.e. ACORN) will have to pretend that
182 * it uses the slash, and do its own mapping of period <-> slash.
183 * Note that the VM system uses a "flat" directory, and thus uses
184 * the empty string for "PATH_SEP".
190 # define PATH_SEP ":"
192 #if defined(WINDOWS) || defined(WINNT)
194 # define PATH_SEP "\\"
198 # define PATH_SEP "\\"
202 # define PATH_SEP "/"
207 * The Macintosh allows the use of a "file type" when creating a file
209 #if defined(MACINTOSH) || defined(MACH_O_CARBON)
210 # define FILE_TYPE_TEXT 'TEXT'
211 # define FILE_TYPE_DATA 'DATA'
212 # define FILE_TYPE_SAVE 'SAVE'
213 # define FILE_TYPE(X) (_ftype = (X))
215 # define FILE_TYPE(X) ((void)0)
220 * OPTION: Define "HAS_STRICMP" only if "stricmp()" exists.
221 * Note that "stricmp()" is not actually used by Angband.
223 /* #define HAS_STRICMP */
226 * Linux has "stricmp()" with a different name
230 # define stricmp strcasecmp
235 * OPTION: Define "HAVE_USLEEP" only if "usleep()" exists.
237 * Note that this is only relevant for "SET_UID" machines.
238 * Note that new "SOLARIS" and "SGI" machines have "usleep()".
240 #if defined(SET_UID) && !defined(HAVE_CONFIG_H)
241 # if !defined(HPUX) && !defined(ULTRIX) && !defined(ISC)
248 # define HAVE_USLEEP /* Set for gcc (djgpp-v2), TY */
254 # define iskanji(x) (((unsigned char)(x) >= 0xa1 && (unsigned char)(x) <= 0xfe) || (unsigned char)(x) == 0x8e)
255 # define iskana(x) (0)
257 # define iskanji(x) ((0x81 <= (unsigned char)(x) && (unsigned char)(x) <= 0x9f) || (0xe0 <= (unsigned char)(x) && (unsigned char)(x) <= 0xfc))
258 # define iskana(x) (((unsigned char)(x) >= 0xA0) && ((unsigned char)(x) <= 0xDF))
260 # error Oops! Please define "EUC" or "SJIS" for kanji-code of your system.
264 #endif /* INCLUDED_H_CONFIG_H */