diff options
Diffstat (limited to 'README')
-rw-r--r-- | README | 91 |
1 files changed, 49 insertions, 42 deletions
@@ -1,55 +1,62 @@ | |||
1 | zlib 1.0 is a general purpose data compression library. | 1 | zlib 1.0.1 is a general purpose data compression library. All the code |
2 | All the code is reentrant (thread safe). | 2 | is reentrant (thread safe). The data format used by the zlib library |
3 | 3 | is described in the files zlib-3.3.doc, deflate-1.3.doc and | |
4 | The data format used by the zlib library is described in the | 4 | gzip-4.3.doc, available in various formats from |
5 | files zlib-3.2.doc, deflate-1.2.doc and gzip-4.2.doc, available | 5 | ftp://swrinde.nde.swri.edu/pub/png/documents/zlib/ |
6 | in ftp://ftp.uu.net/pub/archiving/zip/doc | ||
7 | 6 | ||
8 | All functions of the compression library are documented in the file | 7 | All functions of the compression library are documented in the file |
9 | zlib.h. A usage example of the library is given in the file example.c | 8 | zlib.h. A usage example of the library is given in the file example.c |
10 | which also tests that the library is working correctly. Another | 9 | which also tests that the library is working correctly. Another |
11 | example is given in the file minigzip.c. | 10 | example is given in the file minigzip.c. The compression library itself |
12 | 11 | is composed of all source files except example.c and minigzip.c. | |
13 | To compile all files and run the test program, just type: make test | 12 | |
14 | (For MSDOS, use one of the special makefiles such as Makefile.msc; | 13 | To compile all files and run the test program, follow the instructions |
15 | for VMS, use Make_vms.com or descrip.mms.) | 14 | given at the top of Makefile. In short "make test; make install" |
16 | To install the zlib library (libz.a) in /usr/local/lib, type: make install | 15 | should work for most machines. For MSDOS, use one of the special |
17 | To install in a different directory, use for example: | 16 | makefiles such as Makefile.msc; for VMS, use Make_vms.com or descrip.mms. |
18 | make install prefix=$HOME | 17 | |
19 | This will install in $HOME/lib instead of /usr/local/lib. | 18 | Questions about zlib should be sent to <zlib@quest.jpl.nasa.gov> or, |
20 | 19 | if this fails, to the addresses given below in the Copyright section. | |
21 | Questions about zlib should be sent to <zlib@quest.jpl.nasa.gov>. | 20 | |
22 | 21 | The changes made in version 1.0.1 are documented in the file ChangeLog. | |
23 | The changes made in version 1.0 are documented in the file ChangeLog. | 22 | Version number 1.0 was skipped to avoid confusion with version 0.99 |
24 | The main changes since 0.95 are: | 23 | which had some references to 1.0 already. The main changes since 0.99 are: |
25 | - allow compression level 0 (no compression) | 24 | |
26 | - add deflateParams in zlib.h: allow dynamic change of compression level | 25 | - fix array overlay in deflate.c which sometimes caused bad compressed data |
27 | and compression strategy. | 26 | - fix inflate bug with empty stored block |
28 | - test large buffers and deflateParams in example.c | 27 | - fix MSDOS medium model which was broken in 0.99 |
29 | - declare Z_DEFLATED in zlib.h (possible parameter for deflateInit2) | 28 | - fix deflateParams() which could generated bad compressed data. |
30 | - fixes for 64-bit systems (needed for Alpha and Cray) | 29 | - added an INDEX file |
31 | - always return Z_BUF_ERROR when deflate() has nothing to do | 30 | - new makefiles for DJGPP (Makefile.dj2), 32-bit Borland (Makefile.b32), |
32 | - fix some very unlikely race conditions. | 31 | Watcom (Makefile.wat), Amiga SAS/C (Makefile.sas) |
33 | - several minor fixes for better portability | 32 | - several portability improvements |
34 | - free in reverse order of allocation to help memory manager | ||
35 | 33 | ||
36 | Notes for some targets: | 34 | Notes for some targets: |
37 | 35 | ||
38 | - For MSDOS, the small and medium models have been tested only with | 36 | - For Turbo C the small model is supported only with reduced performance to |
39 | Microsoft C. (This should work for Borland C also, but I don't have | 37 | avoid any far allocation; it was tested with -DMAX_WBITS=11 -DMAX_MEM_LEVEL=3 |
40 | a Borland compiler to test with.) The small model was tested with | ||
41 | Turbo C but only with reduced performance to avoid any far | ||
42 | allocation; it was tested with -DMAX_WBITS=11 -DMAX_MEM_LEVEL=3 | ||
43 | |||
44 | MS Visual C++1.5 in far model gives: | ||
45 | warning C4746: 'z_errmsg' : unsized array treated as '__far' | ||
46 | warning C4746: 'inflate_mask' : unsized array treated as '__far' | ||
47 | Ignore those warnings. | ||
48 | 38 | ||
49 | - For 64-bit Iris, deflate.c must be compiled without any optimization. | 39 | - For 64-bit Iris, deflate.c must be compiled without any optimization. |
50 | With -O, one libpng test fails. The test works in 32 bit mode (with the | 40 | With -O, one libpng test fails. The test works in 32 bit mode (with |
51 | -32 compiler flag). | 41 | the -32 compiler flag). |
42 | |||
43 | - zlib doesn't work with gcc 2.6.3 on a DEC 3000/300LX under OSF/1 2.1 | ||
44 | it works when compiled with cc. | ||
45 | |||
46 | - zlib doesn't work on HP-UX 9.05 with one cc compiler (the one not | ||
47 | accepting the -O option). It works with the other cc compiler. | ||
48 | |||
49 | A Perl interface to zlib written by Paul Marquess <pmarquess@bfsec.bt.co.uk> | ||
50 | is in the CPAN (Comprehensive Perl Archive Network) sites, such as: | ||
51 | ftp://ftp.cis.ufl.edu/pub/perl/CPAN/modules/by-module/Compress/Compress-Zlib* | ||
52 | |||
53 | |||
54 | Acknowledgments: | ||
52 | 55 | ||
56 | The deflate format used by zlib was defined by Phil Katz. The deflate | ||
57 | and zlib specifications were written by Peter Deutsch. Thanks to all the | ||
58 | people who reported problems and suggested various improvements in zlib; | ||
59 | they are too numerous to cite here. | ||
53 | 60 | ||
54 | Copyright notice: | 61 | Copyright notice: |
55 | 62 | ||