1 /* config.h: master configuration file, included first by all compilable
2 source files (not headers).
4 Copyright 1993, 1995, 1996, 1997, 2008 Karl Berry.
5 Copyright 2000, 2003, 2004, 2005 Olaf Weber.
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Lesser General Public
9 License as published by the Free Software Foundation; either
10 version 2.1 of the License, or (at your option) any later version.
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Lesser General Public License for more details.
17 You should have received a copy of the GNU Lesser General Public License
18 along with this library; if not, see <http://www.gnu.org/licenses/>. */
20 #ifndef KPATHSEA_CONFIG_H
21 #define KPATHSEA_CONFIG_H
23 /* System defines are for non-Unix systems only. (Testing for all Unix
24 variations should be done in configure.) Presently the defines used
25 are: AMIGA DOS OS2 WIN32. I do not use any of these systems myself;
26 if you do, I'd be grateful for any changes. --olaf@infovore.xs4all.nl */
28 #if defined(DJGPP) || defined(__DJGPP__) || \
29 defined(CYGWIN) || defined(__CYGWIN__) || \
30 defined(CYGWIN32) || defined(__CYGWIN32__) || \
31 defined(MINGW32) || defined(__MINGW32__)
32 #define __i386_pc_gnu__
35 /* If we have either DOS or OS2, we are DOSISH. Cygwin pretends to be
36 * unix, mostly, so don't include it here.
39 defined(MSDOS) || defined(__MSDOS__) || defined(DOS) || \
40 defined(WIN32) || defined(__WIN32__) || defined(_WIN32) || \
41 defined(DJGPP) || defined(__DJGPP__) || \
42 defined(MINGW32) || defined(__MINGW32__)
46 /* case-insensitive filename comparisons? */
48 #define MONOCASE_FILENAMES
53 #define DEV_NULL "NUL"
55 #define DEV_NULL "/dev/null"
62 #endif /* not WIN32 */
64 /* System dependencies that are figured out by `configure'. */
65 #include <kpathsea/c-auto.h>
68 #include <fcntl.h> /* for long filenames' stuff */
69 #include <dir.h> /* for `getdisk' */
70 #include <io.h> /* for `setmode' */
73 /* Some drivers have partially integrated kpathsea changes. */
78 #include <kpathsea/c-std.h> /* <stdio.h>, <math.h>, etc. */
80 #include <kpathsea/c-proto.h> /* Macros to discard or keep prototypes. */
83 This must be included after "c-proto.h"
84 but before "lib.h". FP.
88 # include <win32lib.h>
90 # include "win32lib.h"
94 #include <kpathsea/debug.h> /* Runtime tracing. */
95 #include <kpathsea/lib.h> /* STREQ, etc. */
96 #include <kpathsea/types.h> /* <sys/types.h>, boolean, string, etc. */
97 #include <kpathsea/progname.h> /* for program_invocation_*name */
100 /* If you want to find subdirectories in a directory with non-Unix
101 semantics (specifically, if a directory with no subdirectories does
102 not have exactly two links), define this. */
103 #if !defined (VMS) && !defined (VMCMS)
104 #if !defined (DOSISH) || defined(__DJGPP__)
105 /* Surprise! DJGPP returns st_nlink exactly like on Unix. */
106 #define ST_NLINK_TRICK
107 #endif /* either not DOSISH or __DJGPP__ */
108 #endif /* not DOS and not VMS and not VMCMS */
111 /* No popen/pclose on Amiga, but rather than put #ifdef's in tex-make.c,
112 let's get rid of the functions here. (CallMF will automatically
113 generate fonts.) pclose must not be simply empty, since it still
114 occurs in a comparison. */
115 #define popen(cmd, mode) NULL
116 #define pclose(file) 0
120 #define access ln_access
121 #define chmod ln_chmod
122 #define creat ln_creat
123 #define fopen ln_fopen
124 #define freopen ln_freopen
125 #define lstat ln_lstat
127 #define remove ln_remove
128 #define rename ln_rename
129 #define sopen ln_sopen
131 #define unlink ln_unlink
134 #endif /* not KPATHSEA_CONFIG_H */