diff options
Diffstat (limited to 'zconf.in.h')
-rw-r--r-- | zconf.in.h | 280 |
1 files changed, 280 insertions, 0 deletions
diff --git a/zconf.in.h b/zconf.in.h new file mode 100644 index 0000000..8ef845e --- /dev/null +++ b/zconf.in.h | |||
@@ -0,0 +1,280 @@ | |||
1 | /* zconf.h -- configuration of the zlib compression library | ||
2 | * Copyright (C) 1995-2003 Jean-loup Gailly. | ||
3 | * For conditions of distribution and use, see copyright notice in zlib.h | ||
4 | */ | ||
5 | |||
6 | /* @(#) $Id$ */ | ||
7 | |||
8 | #ifndef _ZCONF_H | ||
9 | #define _ZCONF_H | ||
10 | |||
11 | /* | ||
12 | * If you *really* need a unique prefix for all types and library functions, | ||
13 | * compile with -DZ_PREFIX. The "standard" zlib should be compiled without it. | ||
14 | */ | ||
15 | #ifdef Z_PREFIX | ||
16 | # define deflateInit_ z_deflateInit_ | ||
17 | # define deflate z_deflate | ||
18 | # define deflateEnd z_deflateEnd | ||
19 | # define inflateInit_ z_inflateInit_ | ||
20 | # define inflate z_inflate | ||
21 | # define inflateEnd z_inflateEnd | ||
22 | # define deflateInit2_ z_deflateInit2_ | ||
23 | # define deflateSetDictionary z_deflateSetDictionary | ||
24 | # define deflateCopy z_deflateCopy | ||
25 | # define deflateReset z_deflateReset | ||
26 | # define deflateParams z_deflateParams | ||
27 | # define deflateBound z_deflateBound | ||
28 | # define inflateInit2_ z_inflateInit2_ | ||
29 | # define inflateSetDictionary z_inflateSetDictionary | ||
30 | # define inflateSync z_inflateSync | ||
31 | # define inflateSyncPoint z_inflateSyncPoint | ||
32 | # define inflateCopy z_inflateCopy | ||
33 | # define inflateReset z_inflateReset | ||
34 | # define compress z_compress | ||
35 | # define compress2 z_compress2 | ||
36 | # define compressBound z_compressBound | ||
37 | # define uncompress z_uncompress | ||
38 | # define adler32 z_adler32 | ||
39 | # define crc32 z_crc32 | ||
40 | # define get_crc_table z_get_crc_table | ||
41 | |||
42 | # define Byte z_Byte | ||
43 | # define uInt z_uInt | ||
44 | # define uLong z_uLong | ||
45 | # define Bytef z_Bytef | ||
46 | # define charf z_charf | ||
47 | # define intf z_intf | ||
48 | # define uIntf z_uIntf | ||
49 | # define uLongf z_uLongf | ||
50 | # define voidpf z_voidpf | ||
51 | # define voidp z_voidp | ||
52 | #endif | ||
53 | |||
54 | #if (defined(_WIN32) || defined(__WIN32__)) && !defined(WIN32) | ||
55 | # define WIN32 | ||
56 | #endif | ||
57 | #if defined(__GNUC__) || defined(WIN32) || defined(__386__) || defined(i386) | ||
58 | # ifndef __32BIT__ | ||
59 | # define __32BIT__ | ||
60 | # endif | ||
61 | #endif | ||
62 | #if defined(__MSDOS__) && !defined(MSDOS) | ||
63 | # define MSDOS | ||
64 | #endif | ||
65 | |||
66 | /* | ||
67 | * Compile with -DMAXSEG_64K if the alloc function cannot allocate more | ||
68 | * than 64k bytes at a time (needed on systems with 16-bit int). | ||
69 | */ | ||
70 | #if defined(MSDOS) && !defined(__32BIT__) | ||
71 | # define MAXSEG_64K | ||
72 | #endif | ||
73 | #ifdef MSDOS | ||
74 | # define UNALIGNED_OK | ||
75 | #endif | ||
76 | |||
77 | #if (defined(MSDOS) || defined(_WINDOWS) || defined(WIN32)) && !defined(STDC) | ||
78 | # define STDC | ||
79 | #endif | ||
80 | #if defined(__STDC__) || defined(__cplusplus) || defined(__OS2__) | ||
81 | # ifndef STDC | ||
82 | # define STDC | ||
83 | # endif | ||
84 | #endif | ||
85 | |||
86 | #if defined __HOS_AIX__ | ||
87 | # ifndef STDC | ||
88 | # define STDC | ||
89 | # endif | ||
90 | #endif | ||
91 | |||
92 | #ifndef STDC | ||
93 | # ifndef const /* cannot use !defined(STDC) && !defined(const) on Mac */ | ||
94 | # define const /* note: need a more gentle solution here */ | ||
95 | # endif | ||
96 | #endif | ||
97 | |||
98 | /* Some Mac compilers merge all .h files incorrectly: */ | ||
99 | #if defined(__MWERKS__) || defined(applec) ||defined(THINK_C) ||defined(__SC__) | ||
100 | # define NO_DUMMY_DECL | ||
101 | #endif | ||
102 | |||
103 | /* Old Borland C incorrectly complains about missing returns: */ | ||
104 | #if defined(__BORLANDC__) && (__BORLANDC__ < 0x500) | ||
105 | # define NEED_DUMMY_RETURN | ||
106 | #endif | ||
107 | |||
108 | |||
109 | /* Maximum value for memLevel in deflateInit2 */ | ||
110 | #ifndef MAX_MEM_LEVEL | ||
111 | # ifdef MAXSEG_64K | ||
112 | # define MAX_MEM_LEVEL 8 | ||
113 | # else | ||
114 | # define MAX_MEM_LEVEL 9 | ||
115 | # endif | ||
116 | #endif | ||
117 | |||
118 | /* Maximum value for windowBits in deflateInit2 and inflateInit2. | ||
119 | * WARNING: reducing MAX_WBITS makes minigzip unable to extract .gz files | ||
120 | * created by gzip. (Files created by minigzip can still be extracted by | ||
121 | * gzip.) | ||
122 | */ | ||
123 | #ifndef MAX_WBITS | ||
124 | # define MAX_WBITS 15 /* 32K LZ77 window */ | ||
125 | #endif | ||
126 | |||
127 | /* The memory requirements for deflate are (in bytes): | ||
128 | (1 << (windowBits+2)) + (1 << (memLevel+9)) | ||
129 | that is: 128K for windowBits=15 + 128K for memLevel = 8 (default values) | ||
130 | plus a few kilobytes for small objects. For example, if you want to reduce | ||
131 | the default memory requirements from 256K to 128K, compile with | ||
132 | make CFLAGS="-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7" | ||
133 | Of course this will generally degrade compression (there's no free lunch). | ||
134 | |||
135 | The memory requirements for inflate are (in bytes) 1 << windowBits | ||
136 | that is, 32K for windowBits=15 (default value) plus a few kilobytes | ||
137 | for small objects. | ||
138 | */ | ||
139 | |||
140 | /* Type declarations */ | ||
141 | |||
142 | #ifndef OF /* function prototypes */ | ||
143 | # ifdef STDC | ||
144 | # define OF(args) args | ||
145 | # else | ||
146 | # define OF(args) () | ||
147 | # endif | ||
148 | #endif | ||
149 | |||
150 | /* The following definitions for FAR are needed only for MSDOS mixed | ||
151 | * model programming (small or medium model with some far allocations). | ||
152 | * This was tested only with MSC; for other MSDOS compilers you may have | ||
153 | * to define NO_MEMCPY in zutil.h. If you don't need the mixed model, | ||
154 | * just define FAR to be empty. | ||
155 | */ | ||
156 | #if (defined(M_I86SM) || defined(M_I86MM)) && !defined(__32BIT__) | ||
157 | /* MSC small or medium model */ | ||
158 | # define SMALL_MEDIUM | ||
159 | # ifdef _MSC_VER | ||
160 | # define FAR _far | ||
161 | # else | ||
162 | # define FAR far | ||
163 | # endif | ||
164 | #endif | ||
165 | #if defined(__BORLANDC__) && (defined(__SMALL__) || defined(__MEDIUM__)) | ||
166 | # ifndef __32BIT__ | ||
167 | # define SMALL_MEDIUM | ||
168 | # define FAR _far | ||
169 | # endif | ||
170 | #endif | ||
171 | |||
172 | /* Compile with -DZLIB_DLL for Windows DLL support */ | ||
173 | #if defined(ZLIB_DLL) | ||
174 | # if defined(_WINDOWS) || defined(WINDOWS) | ||
175 | # ifdef FAR | ||
176 | # undef FAR | ||
177 | # endif | ||
178 | # include <windows.h> | ||
179 | # define ZEXPORT WINAPI | ||
180 | # ifdef WIN32 | ||
181 | # define ZEXPORTVA WINAPIV | ||
182 | # else | ||
183 | # define ZEXPORTVA FAR _cdecl _export | ||
184 | # endif | ||
185 | # endif | ||
186 | # if defined (__BORLANDC__) | ||
187 | # if (__BORLANDC__ >= 0x0500) && defined (WIN32) | ||
188 | # include <windows.h> | ||
189 | # define ZEXPORT __declspec(dllexport) WINAPI | ||
190 | # define ZEXPORTRVA __declspec(dllexport) WINAPIV | ||
191 | # else | ||
192 | # if defined (_Windows) && defined (__DLL__) | ||
193 | # define ZEXPORT _export | ||
194 | # define ZEXPORTVA _export | ||
195 | # endif | ||
196 | # endif | ||
197 | # endif | ||
198 | #endif | ||
199 | |||
200 | #if defined (__BEOS__) | ||
201 | # if defined (ZLIB_DLL) | ||
202 | # define ZEXTERN extern __declspec(dllexport) | ||
203 | # else | ||
204 | # define ZEXTERN extern __declspec(dllimport) | ||
205 | # endif | ||
206 | #endif | ||
207 | |||
208 | #ifndef ZEXPORT | ||
209 | # define ZEXPORT | ||
210 | #endif | ||
211 | #ifndef ZEXPORTVA | ||
212 | # define ZEXPORTVA | ||
213 | #endif | ||
214 | #ifndef ZEXTERN | ||
215 | # define ZEXTERN extern | ||
216 | #endif | ||
217 | |||
218 | #ifndef FAR | ||
219 | # define FAR | ||
220 | #endif | ||
221 | |||
222 | #if !defined(__MACTYPES__) | ||
223 | typedef unsigned char Byte; /* 8 bits */ | ||
224 | #endif | ||
225 | typedef unsigned int uInt; /* 16 bits or more */ | ||
226 | typedef unsigned long uLong; /* 32 bits or more */ | ||
227 | |||
228 | #ifdef SMALL_MEDIUM | ||
229 | /* Borland C/C++ and some old MSC versions ignore FAR inside typedef */ | ||
230 | # define Bytef Byte FAR | ||
231 | #else | ||
232 | typedef Byte FAR Bytef; | ||
233 | #endif | ||
234 | typedef char FAR charf; | ||
235 | typedef int FAR intf; | ||
236 | typedef uInt FAR uIntf; | ||
237 | typedef uLong FAR uLongf; | ||
238 | |||
239 | #ifdef STDC | ||
240 | typedef void const *voidpc; | ||
241 | typedef void FAR *voidpf; | ||
242 | typedef void *voidp; | ||
243 | #else | ||
244 | typedef Byte const *voidpc; | ||
245 | typedef Byte FAR *voidpf; | ||
246 | typedef Byte *voidp; | ||
247 | #endif | ||
248 | |||
249 | #if 0 /* HAVE_UNISTD_H -- this line is updated by ./configure */ | ||
250 | # include <sys/types.h> /* for off_t */ | ||
251 | # include <unistd.h> /* for SEEK_* and off_t */ | ||
252 | # define z_off_t off_t | ||
253 | #endif | ||
254 | #ifndef SEEK_SET | ||
255 | # define SEEK_SET 0 /* Seek from beginning of file. */ | ||
256 | # define SEEK_CUR 1 /* Seek from current position. */ | ||
257 | # define SEEK_END 2 /* Set file pointer to EOF plus "offset" */ | ||
258 | #endif | ||
259 | #ifndef z_off_t | ||
260 | # define z_off_t long | ||
261 | #endif | ||
262 | |||
263 | /* MVS linker does not support external names larger than 8 bytes */ | ||
264 | #if defined(__MVS__) | ||
265 | # pragma map(deflateInit_,"DEIN") | ||
266 | # pragma map(deflateInit2_,"DEIN2") | ||
267 | # pragma map(deflateEnd,"DEEND") | ||
268 | # pragma map(deflateBound,"DEBND") | ||
269 | # pragma map(inflateInit_,"ININ") | ||
270 | # pragma map(inflateInit2_,"ININ2") | ||
271 | # pragma map(inflateEnd,"INEND") | ||
272 | # pragma map(inflateSync,"INSY") | ||
273 | # pragma map(inflateSetDictionary,"INSEDI") | ||
274 | # pragma map(compressBound,"CMBND") | ||
275 | # pragma map(inflate_table,"INTABL") | ||
276 | # pragma map(inflate_fast,"INFA") | ||
277 | # pragma map(inflate_copyright,"INCOPY") | ||
278 | #endif | ||
279 | |||
280 | #endif /* _ZCONF_H */ | ||