source: rtems/cpukit/zlib/zconf.h.in @ c130387

5
Last change on this file since c130387 was 9b4422a2, checked in by Joel Sherrill <joel.sherrill@…>, on 05/03/12 at 15:09:24

Remove All CVS Id Strings Possible Using a Script

Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines

next to each other after Id string line removed.

+ remove entire comment blocks which only exited to

contain CVS Ids

+ If the processing left a blank line at the top of

a file, it was removed.

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