cannam@89
|
1 /* zconf.h -- configuration of the zlib compression library
|
cannam@89
|
2 * Copyright (C) 1995-2012 Jean-loup Gailly.
|
cannam@89
|
3 * For conditions of distribution and use, see copyright notice in zlib.h
|
cannam@89
|
4 */
|
cannam@89
|
5
|
cannam@89
|
6 /* @(#) $Id$ */
|
cannam@89
|
7
|
cannam@89
|
8 #ifndef ZCONF_H
|
cannam@89
|
9 #define ZCONF_H
|
cannam@89
|
10
|
cannam@89
|
11 /*
|
cannam@89
|
12 * If you *really* need a unique prefix for all types and library functions,
|
cannam@89
|
13 * compile with -DZ_PREFIX. The "standard" zlib should be compiled without it.
|
cannam@89
|
14 * Even better than compiling with -DZ_PREFIX would be to use configure to set
|
cannam@89
|
15 * this permanently in zconf.h using "./configure --zprefix".
|
cannam@89
|
16 */
|
cannam@89
|
17 #ifdef Z_PREFIX /* may be set to #if 1 by ./configure */
|
cannam@89
|
18 # define Z_PREFIX_SET
|
cannam@89
|
19
|
cannam@89
|
20 /* all linked symbols */
|
cannam@89
|
21 # define _dist_code z__dist_code
|
cannam@89
|
22 # define _length_code z__length_code
|
cannam@89
|
23 # define _tr_align z__tr_align
|
cannam@89
|
24 # define _tr_flush_block z__tr_flush_block
|
cannam@89
|
25 # define _tr_init z__tr_init
|
cannam@89
|
26 # define _tr_stored_block z__tr_stored_block
|
cannam@89
|
27 # define _tr_tally z__tr_tally
|
cannam@89
|
28 # define adler32 z_adler32
|
cannam@89
|
29 # define adler32_combine z_adler32_combine
|
cannam@89
|
30 # define adler32_combine64 z_adler32_combine64
|
cannam@89
|
31 # ifndef Z_SOLO
|
cannam@89
|
32 # define compress z_compress
|
cannam@89
|
33 # define compress2 z_compress2
|
cannam@89
|
34 # define compressBound z_compressBound
|
cannam@89
|
35 # endif
|
cannam@89
|
36 # define crc32 z_crc32
|
cannam@89
|
37 # define crc32_combine z_crc32_combine
|
cannam@89
|
38 # define crc32_combine64 z_crc32_combine64
|
cannam@89
|
39 # define deflate z_deflate
|
cannam@89
|
40 # define deflateBound z_deflateBound
|
cannam@89
|
41 # define deflateCopy z_deflateCopy
|
cannam@89
|
42 # define deflateEnd z_deflateEnd
|
cannam@89
|
43 # define deflateInit2_ z_deflateInit2_
|
cannam@89
|
44 # define deflateInit_ z_deflateInit_
|
cannam@89
|
45 # define deflateParams z_deflateParams
|
cannam@89
|
46 # define deflatePending z_deflatePending
|
cannam@89
|
47 # define deflatePrime z_deflatePrime
|
cannam@89
|
48 # define deflateReset z_deflateReset
|
cannam@89
|
49 # define deflateResetKeep z_deflateResetKeep
|
cannam@89
|
50 # define deflateSetDictionary z_deflateSetDictionary
|
cannam@89
|
51 # define deflateSetHeader z_deflateSetHeader
|
cannam@89
|
52 # define deflateTune z_deflateTune
|
cannam@89
|
53 # define deflate_copyright z_deflate_copyright
|
cannam@89
|
54 # define get_crc_table z_get_crc_table
|
cannam@89
|
55 # ifndef Z_SOLO
|
cannam@89
|
56 # define gz_error z_gz_error
|
cannam@89
|
57 # define gz_intmax z_gz_intmax
|
cannam@89
|
58 # define gz_strwinerror z_gz_strwinerror
|
cannam@89
|
59 # define gzbuffer z_gzbuffer
|
cannam@89
|
60 # define gzclearerr z_gzclearerr
|
cannam@89
|
61 # define gzclose z_gzclose
|
cannam@89
|
62 # define gzclose_r z_gzclose_r
|
cannam@89
|
63 # define gzclose_w z_gzclose_w
|
cannam@89
|
64 # define gzdirect z_gzdirect
|
cannam@89
|
65 # define gzdopen z_gzdopen
|
cannam@89
|
66 # define gzeof z_gzeof
|
cannam@89
|
67 # define gzerror z_gzerror
|
cannam@89
|
68 # define gzflush z_gzflush
|
cannam@89
|
69 # define gzgetc z_gzgetc
|
cannam@89
|
70 # define gzgetc_ z_gzgetc_
|
cannam@89
|
71 # define gzgets z_gzgets
|
cannam@89
|
72 # define gzoffset z_gzoffset
|
cannam@89
|
73 # define gzoffset64 z_gzoffset64
|
cannam@89
|
74 # define gzopen z_gzopen
|
cannam@89
|
75 # define gzopen64 z_gzopen64
|
cannam@89
|
76 # ifdef _WIN32
|
cannam@89
|
77 # define gzopen_w z_gzopen_w
|
cannam@89
|
78 # endif
|
cannam@89
|
79 # define gzprintf z_gzprintf
|
cannam@89
|
80 # define gzputc z_gzputc
|
cannam@89
|
81 # define gzputs z_gzputs
|
cannam@89
|
82 # define gzread z_gzread
|
cannam@89
|
83 # define gzrewind z_gzrewind
|
cannam@89
|
84 # define gzseek z_gzseek
|
cannam@89
|
85 # define gzseek64 z_gzseek64
|
cannam@89
|
86 # define gzsetparams z_gzsetparams
|
cannam@89
|
87 # define gztell z_gztell
|
cannam@89
|
88 # define gztell64 z_gztell64
|
cannam@89
|
89 # define gzungetc z_gzungetc
|
cannam@89
|
90 # define gzwrite z_gzwrite
|
cannam@89
|
91 # endif
|
cannam@89
|
92 # define inflate z_inflate
|
cannam@89
|
93 # define inflateBack z_inflateBack
|
cannam@89
|
94 # define inflateBackEnd z_inflateBackEnd
|
cannam@89
|
95 # define inflateBackInit_ z_inflateBackInit_
|
cannam@89
|
96 # define inflateCopy z_inflateCopy
|
cannam@89
|
97 # define inflateEnd z_inflateEnd
|
cannam@89
|
98 # define inflateGetHeader z_inflateGetHeader
|
cannam@89
|
99 # define inflateInit2_ z_inflateInit2_
|
cannam@89
|
100 # define inflateInit_ z_inflateInit_
|
cannam@89
|
101 # define inflateMark z_inflateMark
|
cannam@89
|
102 # define inflatePrime z_inflatePrime
|
cannam@89
|
103 # define inflateReset z_inflateReset
|
cannam@89
|
104 # define inflateReset2 z_inflateReset2
|
cannam@89
|
105 # define inflateSetDictionary z_inflateSetDictionary
|
cannam@89
|
106 # define inflateSync z_inflateSync
|
cannam@89
|
107 # define inflateSyncPoint z_inflateSyncPoint
|
cannam@89
|
108 # define inflateUndermine z_inflateUndermine
|
cannam@89
|
109 # define inflateResetKeep z_inflateResetKeep
|
cannam@89
|
110 # define inflate_copyright z_inflate_copyright
|
cannam@89
|
111 # define inflate_fast z_inflate_fast
|
cannam@89
|
112 # define inflate_table z_inflate_table
|
cannam@89
|
113 # ifndef Z_SOLO
|
cannam@89
|
114 # define uncompress z_uncompress
|
cannam@89
|
115 # endif
|
cannam@89
|
116 # define zError z_zError
|
cannam@89
|
117 # ifndef Z_SOLO
|
cannam@89
|
118 # define zcalloc z_zcalloc
|
cannam@89
|
119 # define zcfree z_zcfree
|
cannam@89
|
120 # endif
|
cannam@89
|
121 # define zlibCompileFlags z_zlibCompileFlags
|
cannam@89
|
122 # define zlibVersion z_zlibVersion
|
cannam@89
|
123
|
cannam@89
|
124 /* all zlib typedefs in zlib.h and zconf.h */
|
cannam@89
|
125 # define Byte z_Byte
|
cannam@89
|
126 # define Bytef z_Bytef
|
cannam@89
|
127 # define alloc_func z_alloc_func
|
cannam@89
|
128 # define charf z_charf
|
cannam@89
|
129 # define free_func z_free_func
|
cannam@89
|
130 # ifndef Z_SOLO
|
cannam@89
|
131 # define gzFile z_gzFile
|
cannam@89
|
132 # endif
|
cannam@89
|
133 # define gz_header z_gz_header
|
cannam@89
|
134 # define gz_headerp z_gz_headerp
|
cannam@89
|
135 # define in_func z_in_func
|
cannam@89
|
136 # define intf z_intf
|
cannam@89
|
137 # define out_func z_out_func
|
cannam@89
|
138 # define uInt z_uInt
|
cannam@89
|
139 # define uIntf z_uIntf
|
cannam@89
|
140 # define uLong z_uLong
|
cannam@89
|
141 # define uLongf z_uLongf
|
cannam@89
|
142 # define voidp z_voidp
|
cannam@89
|
143 # define voidpc z_voidpc
|
cannam@89
|
144 # define voidpf z_voidpf
|
cannam@89
|
145
|
cannam@89
|
146 /* all zlib structs in zlib.h and zconf.h */
|
cannam@89
|
147 # define gz_header_s z_gz_header_s
|
cannam@89
|
148 # define internal_state z_internal_state
|
cannam@89
|
149
|
cannam@89
|
150 #endif
|
cannam@89
|
151
|
cannam@89
|
152 #if defined(__MSDOS__) && !defined(MSDOS)
|
cannam@89
|
153 # define MSDOS
|
cannam@89
|
154 #endif
|
cannam@89
|
155 #if (defined(OS_2) || defined(__OS2__)) && !defined(OS2)
|
cannam@89
|
156 # define OS2
|
cannam@89
|
157 #endif
|
cannam@89
|
158 #if defined(_WINDOWS) && !defined(WINDOWS)
|
cannam@89
|
159 # define WINDOWS
|
cannam@89
|
160 #endif
|
cannam@89
|
161 #if defined(_WIN32) || defined(_WIN32_WCE) || defined(__WIN32__)
|
cannam@89
|
162 # ifndef WIN32
|
cannam@89
|
163 # define WIN32
|
cannam@89
|
164 # endif
|
cannam@89
|
165 #endif
|
cannam@89
|
166 #if (defined(MSDOS) || defined(OS2) || defined(WINDOWS)) && !defined(WIN32)
|
cannam@89
|
167 # if !defined(__GNUC__) && !defined(__FLAT__) && !defined(__386__)
|
cannam@89
|
168 # ifndef SYS16BIT
|
cannam@89
|
169 # define SYS16BIT
|
cannam@89
|
170 # endif
|
cannam@89
|
171 # endif
|
cannam@89
|
172 #endif
|
cannam@89
|
173
|
cannam@89
|
174 /*
|
cannam@89
|
175 * Compile with -DMAXSEG_64K if the alloc function cannot allocate more
|
cannam@89
|
176 * than 64k bytes at a time (needed on systems with 16-bit int).
|
cannam@89
|
177 */
|
cannam@89
|
178 #ifdef SYS16BIT
|
cannam@89
|
179 # define MAXSEG_64K
|
cannam@89
|
180 #endif
|
cannam@89
|
181 #ifdef MSDOS
|
cannam@89
|
182 # define UNALIGNED_OK
|
cannam@89
|
183 #endif
|
cannam@89
|
184
|
cannam@89
|
185 #ifdef __STDC_VERSION__
|
cannam@89
|
186 # ifndef STDC
|
cannam@89
|
187 # define STDC
|
cannam@89
|
188 # endif
|
cannam@89
|
189 # if __STDC_VERSION__ >= 199901L
|
cannam@89
|
190 # ifndef STDC99
|
cannam@89
|
191 # define STDC99
|
cannam@89
|
192 # endif
|
cannam@89
|
193 # endif
|
cannam@89
|
194 #endif
|
cannam@89
|
195 #if !defined(STDC) && (defined(__STDC__) || defined(__cplusplus))
|
cannam@89
|
196 # define STDC
|
cannam@89
|
197 #endif
|
cannam@89
|
198 #if !defined(STDC) && (defined(__GNUC__) || defined(__BORLANDC__))
|
cannam@89
|
199 # define STDC
|
cannam@89
|
200 #endif
|
cannam@89
|
201 #if !defined(STDC) && (defined(MSDOS) || defined(WINDOWS) || defined(WIN32))
|
cannam@89
|
202 # define STDC
|
cannam@89
|
203 #endif
|
cannam@89
|
204 #if !defined(STDC) && (defined(OS2) || defined(__HOS_AIX__))
|
cannam@89
|
205 # define STDC
|
cannam@89
|
206 #endif
|
cannam@89
|
207
|
cannam@89
|
208 #if defined(__OS400__) && !defined(STDC) /* iSeries (formerly AS/400). */
|
cannam@89
|
209 # define STDC
|
cannam@89
|
210 #endif
|
cannam@89
|
211
|
cannam@89
|
212 #ifndef STDC
|
cannam@89
|
213 # ifndef const /* cannot use !defined(STDC) && !defined(const) on Mac */
|
cannam@89
|
214 # define const /* note: need a more gentle solution here */
|
cannam@89
|
215 # endif
|
cannam@89
|
216 #endif
|
cannam@89
|
217
|
cannam@89
|
218 #if defined(ZLIB_CONST) && !defined(z_const)
|
cannam@89
|
219 # define z_const const
|
cannam@89
|
220 #else
|
cannam@89
|
221 # define z_const
|
cannam@89
|
222 #endif
|
cannam@89
|
223
|
cannam@89
|
224 /* Some Mac compilers merge all .h files incorrectly: */
|
cannam@89
|
225 #if defined(__MWERKS__)||defined(applec)||defined(THINK_C)||defined(__SC__)
|
cannam@89
|
226 # define NO_DUMMY_DECL
|
cannam@89
|
227 #endif
|
cannam@89
|
228
|
cannam@89
|
229 /* Maximum value for memLevel in deflateInit2 */
|
cannam@89
|
230 #ifndef MAX_MEM_LEVEL
|
cannam@89
|
231 # ifdef MAXSEG_64K
|
cannam@89
|
232 # define MAX_MEM_LEVEL 8
|
cannam@89
|
233 # else
|
cannam@89
|
234 # define MAX_MEM_LEVEL 9
|
cannam@89
|
235 # endif
|
cannam@89
|
236 #endif
|
cannam@89
|
237
|
cannam@89
|
238 /* Maximum value for windowBits in deflateInit2 and inflateInit2.
|
cannam@89
|
239 * WARNING: reducing MAX_WBITS makes minigzip unable to extract .gz files
|
cannam@89
|
240 * created by gzip. (Files created by minigzip can still be extracted by
|
cannam@89
|
241 * gzip.)
|
cannam@89
|
242 */
|
cannam@89
|
243 #ifndef MAX_WBITS
|
cannam@89
|
244 # define MAX_WBITS 15 /* 32K LZ77 window */
|
cannam@89
|
245 #endif
|
cannam@89
|
246
|
cannam@89
|
247 /* The memory requirements for deflate are (in bytes):
|
cannam@89
|
248 (1 << (windowBits+2)) + (1 << (memLevel+9))
|
cannam@89
|
249 that is: 128K for windowBits=15 + 128K for memLevel = 8 (default values)
|
cannam@89
|
250 plus a few kilobytes for small objects. For example, if you want to reduce
|
cannam@89
|
251 the default memory requirements from 256K to 128K, compile with
|
cannam@89
|
252 make CFLAGS="-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7"
|
cannam@89
|
253 Of course this will generally degrade compression (there's no free lunch).
|
cannam@89
|
254
|
cannam@89
|
255 The memory requirements for inflate are (in bytes) 1 << windowBits
|
cannam@89
|
256 that is, 32K for windowBits=15 (default value) plus a few kilobytes
|
cannam@89
|
257 for small objects.
|
cannam@89
|
258 */
|
cannam@89
|
259
|
cannam@89
|
260 /* Type declarations */
|
cannam@89
|
261
|
cannam@89
|
262 #ifndef OF /* function prototypes */
|
cannam@89
|
263 # ifdef STDC
|
cannam@89
|
264 # define OF(args) args
|
cannam@89
|
265 # else
|
cannam@89
|
266 # define OF(args) ()
|
cannam@89
|
267 # endif
|
cannam@89
|
268 #endif
|
cannam@89
|
269
|
cannam@89
|
270 #ifndef Z_ARG /* function prototypes for stdarg */
|
cannam@89
|
271 # if defined(STDC) || defined(Z_HAVE_STDARG_H)
|
cannam@89
|
272 # define Z_ARG(args) args
|
cannam@89
|
273 # else
|
cannam@89
|
274 # define Z_ARG(args) ()
|
cannam@89
|
275 # endif
|
cannam@89
|
276 #endif
|
cannam@89
|
277
|
cannam@89
|
278 /* The following definitions for FAR are needed only for MSDOS mixed
|
cannam@89
|
279 * model programming (small or medium model with some far allocations).
|
cannam@89
|
280 * This was tested only with MSC; for other MSDOS compilers you may have
|
cannam@89
|
281 * to define NO_MEMCPY in zutil.h. If you don't need the mixed model,
|
cannam@89
|
282 * just define FAR to be empty.
|
cannam@89
|
283 */
|
cannam@89
|
284 #ifdef SYS16BIT
|
cannam@89
|
285 # if defined(M_I86SM) || defined(M_I86MM)
|
cannam@89
|
286 /* MSC small or medium model */
|
cannam@89
|
287 # define SMALL_MEDIUM
|
cannam@89
|
288 # ifdef _MSC_VER
|
cannam@89
|
289 # define FAR _far
|
cannam@89
|
290 # else
|
cannam@89
|
291 # define FAR far
|
cannam@89
|
292 # endif
|
cannam@89
|
293 # endif
|
cannam@89
|
294 # if (defined(__SMALL__) || defined(__MEDIUM__))
|
cannam@89
|
295 /* Turbo C small or medium model */
|
cannam@89
|
296 # define SMALL_MEDIUM
|
cannam@89
|
297 # ifdef __BORLANDC__
|
cannam@89
|
298 # define FAR _far
|
cannam@89
|
299 # else
|
cannam@89
|
300 # define FAR far
|
cannam@89
|
301 # endif
|
cannam@89
|
302 # endif
|
cannam@89
|
303 #endif
|
cannam@89
|
304
|
cannam@89
|
305 #if defined(WINDOWS) || defined(WIN32)
|
cannam@89
|
306 /* If building or using zlib as a DLL, define ZLIB_DLL.
|
cannam@89
|
307 * This is not mandatory, but it offers a little performance increase.
|
cannam@89
|
308 */
|
cannam@89
|
309 # ifdef ZLIB_DLL
|
cannam@89
|
310 # if defined(WIN32) && (!defined(__BORLANDC__) || (__BORLANDC__ >= 0x500))
|
cannam@89
|
311 # ifdef ZLIB_INTERNAL
|
cannam@89
|
312 # define ZEXTERN extern __declspec(dllexport)
|
cannam@89
|
313 # else
|
cannam@89
|
314 # define ZEXTERN extern __declspec(dllimport)
|
cannam@89
|
315 # endif
|
cannam@89
|
316 # endif
|
cannam@89
|
317 # endif /* ZLIB_DLL */
|
cannam@89
|
318 /* If building or using zlib with the WINAPI/WINAPIV calling convention,
|
cannam@89
|
319 * define ZLIB_WINAPI.
|
cannam@89
|
320 * Caution: the standard ZLIB1.DLL is NOT compiled using ZLIB_WINAPI.
|
cannam@89
|
321 */
|
cannam@89
|
322 # ifdef ZLIB_WINAPI
|
cannam@89
|
323 # ifdef FAR
|
cannam@89
|
324 # undef FAR
|
cannam@89
|
325 # endif
|
cannam@89
|
326 # include <windows.h>
|
cannam@89
|
327 /* No need for _export, use ZLIB.DEF instead. */
|
cannam@89
|
328 /* For complete Windows compatibility, use WINAPI, not __stdcall. */
|
cannam@89
|
329 # define ZEXPORT WINAPI
|
cannam@89
|
330 # ifdef WIN32
|
cannam@89
|
331 # define ZEXPORTVA WINAPIV
|
cannam@89
|
332 # else
|
cannam@89
|
333 # define ZEXPORTVA FAR CDECL
|
cannam@89
|
334 # endif
|
cannam@89
|
335 # endif
|
cannam@89
|
336 #endif
|
cannam@89
|
337
|
cannam@89
|
338 #if defined (__BEOS__)
|
cannam@89
|
339 # ifdef ZLIB_DLL
|
cannam@89
|
340 # ifdef ZLIB_INTERNAL
|
cannam@89
|
341 # define ZEXPORT __declspec(dllexport)
|
cannam@89
|
342 # define ZEXPORTVA __declspec(dllexport)
|
cannam@89
|
343 # else
|
cannam@89
|
344 # define ZEXPORT __declspec(dllimport)
|
cannam@89
|
345 # define ZEXPORTVA __declspec(dllimport)
|
cannam@89
|
346 # endif
|
cannam@89
|
347 # endif
|
cannam@89
|
348 #endif
|
cannam@89
|
349
|
cannam@89
|
350 #ifndef ZEXTERN
|
cannam@89
|
351 # define ZEXTERN extern
|
cannam@89
|
352 #endif
|
cannam@89
|
353 #ifndef ZEXPORT
|
cannam@89
|
354 # define ZEXPORT
|
cannam@89
|
355 #endif
|
cannam@89
|
356 #ifndef ZEXPORTVA
|
cannam@89
|
357 # define ZEXPORTVA
|
cannam@89
|
358 #endif
|
cannam@89
|
359
|
cannam@89
|
360 #ifndef FAR
|
cannam@89
|
361 # define FAR
|
cannam@89
|
362 #endif
|
cannam@89
|
363
|
cannam@89
|
364 #if !defined(__MACTYPES__)
|
cannam@89
|
365 typedef unsigned char Byte; /* 8 bits */
|
cannam@89
|
366 #endif
|
cannam@89
|
367 typedef unsigned int uInt; /* 16 bits or more */
|
cannam@89
|
368 typedef unsigned long uLong; /* 32 bits or more */
|
cannam@89
|
369
|
cannam@89
|
370 #ifdef SMALL_MEDIUM
|
cannam@89
|
371 /* Borland C/C++ and some old MSC versions ignore FAR inside typedef */
|
cannam@89
|
372 # define Bytef Byte FAR
|
cannam@89
|
373 #else
|
cannam@89
|
374 typedef Byte FAR Bytef;
|
cannam@89
|
375 #endif
|
cannam@89
|
376 typedef char FAR charf;
|
cannam@89
|
377 typedef int FAR intf;
|
cannam@89
|
378 typedef uInt FAR uIntf;
|
cannam@89
|
379 typedef uLong FAR uLongf;
|
cannam@89
|
380
|
cannam@89
|
381 #ifdef STDC
|
cannam@89
|
382 typedef void const *voidpc;
|
cannam@89
|
383 typedef void FAR *voidpf;
|
cannam@89
|
384 typedef void *voidp;
|
cannam@89
|
385 #else
|
cannam@89
|
386 typedef Byte const *voidpc;
|
cannam@89
|
387 typedef Byte FAR *voidpf;
|
cannam@89
|
388 typedef Byte *voidp;
|
cannam@89
|
389 #endif
|
cannam@89
|
390
|
cannam@91
|
391 #define Z_U4 unsigned
|
cannam@89
|
392 /* ./configure put the #define Z_U4 here */
|
cannam@89
|
393
|
cannam@89
|
394 #if !defined(Z_U4) && !defined(Z_SOLO) && defined(STDC)
|
cannam@89
|
395 # include <limits.h>
|
cannam@89
|
396 # if (UINT_MAX == 0xffffffffUL)
|
cannam@89
|
397 # define Z_U4 unsigned
|
cannam@89
|
398 # else
|
cannam@89
|
399 # if (ULONG_MAX == 0xffffffffUL)
|
cannam@89
|
400 # define Z_U4 unsigned long
|
cannam@89
|
401 # else
|
cannam@89
|
402 # if (USHRT_MAX == 0xffffffffUL)
|
cannam@89
|
403 # define Z_U4 unsigned short
|
cannam@89
|
404 # endif
|
cannam@89
|
405 # endif
|
cannam@89
|
406 # endif
|
cannam@89
|
407 #endif
|
cannam@89
|
408
|
cannam@89
|
409 #ifdef Z_U4
|
cannam@89
|
410 typedef Z_U4 z_crc_t;
|
cannam@89
|
411 #else
|
cannam@89
|
412 typedef unsigned long z_crc_t;
|
cannam@89
|
413 #endif
|
cannam@91
|
414
|
cannam@89
|
415 #if 1 /* was set to #if 1 by ./configure */
|
cannam@89
|
416 # define Z_HAVE_UNISTD_H
|
cannam@89
|
417 #endif
|
cannam@91
|
418
|
cannam@89
|
419 #if 1 /* was set to #if 1 by ./configure */
|
cannam@89
|
420 # define Z_HAVE_STDARG_H
|
cannam@89
|
421 #endif
|
cannam@89
|
422
|
cannam@89
|
423 #ifdef STDC
|
cannam@89
|
424 # ifndef Z_SOLO
|
cannam@89
|
425 # include <sys/types.h> /* for off_t */
|
cannam@89
|
426 # endif
|
cannam@89
|
427 #endif
|
cannam@89
|
428
|
cannam@89
|
429 #ifdef _WIN32
|
cannam@89
|
430 # include <stddef.h> /* for wchar_t */
|
cannam@89
|
431 #endif
|
cannam@89
|
432
|
cannam@89
|
433 /* a little trick to accommodate both "#define _LARGEFILE64_SOURCE" and
|
cannam@89
|
434 * "#define _LARGEFILE64_SOURCE 1" as requesting 64-bit operations, (even
|
cannam@89
|
435 * though the former does not conform to the LFS document), but considering
|
cannam@89
|
436 * both "#undef _LARGEFILE64_SOURCE" and "#define _LARGEFILE64_SOURCE 0" as
|
cannam@89
|
437 * equivalently requesting no 64-bit operations
|
cannam@89
|
438 */
|
cannam@89
|
439 #if defined(LARGEFILE64_SOURCE) && -_LARGEFILE64_SOURCE - -1 == 1
|
cannam@89
|
440 # undef _LARGEFILE64_SOURCE
|
cannam@89
|
441 #endif
|
cannam@89
|
442
|
cannam@89
|
443 #if defined(__WATCOMC__) && !defined(Z_HAVE_UNISTD_H)
|
cannam@89
|
444 # define Z_HAVE_UNISTD_H
|
cannam@89
|
445 #endif
|
cannam@89
|
446 #ifndef Z_SOLO
|
cannam@89
|
447 # if defined(Z_HAVE_UNISTD_H) || defined(LARGEFILE64_SOURCE)
|
cannam@89
|
448 # include <unistd.h> /* for SEEK_*, off_t, and _LFS64_LARGEFILE */
|
cannam@89
|
449 # ifdef VMS
|
cannam@89
|
450 # include <unixio.h> /* for off_t */
|
cannam@89
|
451 # endif
|
cannam@89
|
452 # ifndef z_off_t
|
cannam@89
|
453 # define z_off_t off_t
|
cannam@89
|
454 # endif
|
cannam@89
|
455 # endif
|
cannam@89
|
456 #endif
|
cannam@89
|
457
|
cannam@89
|
458 #if defined(_LFS64_LARGEFILE) && _LFS64_LARGEFILE-0
|
cannam@89
|
459 # define Z_LFS64
|
cannam@89
|
460 #endif
|
cannam@89
|
461
|
cannam@89
|
462 #if defined(_LARGEFILE64_SOURCE) && defined(Z_LFS64)
|
cannam@89
|
463 # define Z_LARGE64
|
cannam@89
|
464 #endif
|
cannam@89
|
465
|
cannam@89
|
466 #if defined(_FILE_OFFSET_BITS) && _FILE_OFFSET_BITS-0 == 64 && defined(Z_LFS64)
|
cannam@89
|
467 # define Z_WANT64
|
cannam@89
|
468 #endif
|
cannam@89
|
469
|
cannam@89
|
470 #if !defined(SEEK_SET) && !defined(Z_SOLO)
|
cannam@89
|
471 # define SEEK_SET 0 /* Seek from beginning of file. */
|
cannam@89
|
472 # define SEEK_CUR 1 /* Seek from current position. */
|
cannam@89
|
473 # define SEEK_END 2 /* Set file pointer to EOF plus "offset" */
|
cannam@89
|
474 #endif
|
cannam@89
|
475
|
cannam@89
|
476 #ifndef z_off_t
|
cannam@89
|
477 # define z_off_t long
|
cannam@89
|
478 #endif
|
cannam@89
|
479
|
cannam@89
|
480 #if !defined(_WIN32) && defined(Z_LARGE64)
|
cannam@89
|
481 # define z_off64_t off64_t
|
cannam@89
|
482 #else
|
cannam@89
|
483 # if defined(_WIN32) && !defined(__GNUC__) && !defined(Z_SOLO)
|
cannam@89
|
484 # define z_off64_t __int64
|
cannam@89
|
485 # else
|
cannam@89
|
486 # define z_off64_t z_off_t
|
cannam@89
|
487 # endif
|
cannam@89
|
488 #endif
|
cannam@89
|
489
|
cannam@89
|
490 /* MVS linker does not support external names larger than 8 bytes */
|
cannam@89
|
491 #if defined(__MVS__)
|
cannam@89
|
492 #pragma map(deflateInit_,"DEIN")
|
cannam@89
|
493 #pragma map(deflateInit2_,"DEIN2")
|
cannam@89
|
494 #pragma map(deflateEnd,"DEEND")
|
cannam@89
|
495 #pragma map(deflateBound,"DEBND")
|
cannam@89
|
496 #pragma map(inflateInit_,"ININ")
|
cannam@89
|
497 #pragma map(inflateInit2_,"ININ2")
|
cannam@89
|
498 #pragma map(inflateEnd,"INEND")
|
cannam@89
|
499 #pragma map(inflateSync,"INSY")
|
cannam@89
|
500 #pragma map(inflateSetDictionary,"INSEDI")
|
cannam@89
|
501 #pragma map(compressBound,"CMBND")
|
cannam@89
|
502 #pragma map(inflate_table,"INTABL")
|
cannam@89
|
503 #pragma map(inflate_fast,"INFA")
|
cannam@89
|
504 #pragma map(inflate_copyright,"INCOPY")
|
cannam@89
|
505 #endif
|
cannam@89
|
506
|
cannam@91
|
507 #endif /* ZCONF_H */
|