Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 1 | .TH ZLIB 3 "29 Jan 2012" |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 2 | .SH NAME |
| 3 | zlib \- compression/decompression library |
| 4 | .SH SYNOPSIS |
| 5 | [see |
| 6 | .I zlib.h |
| 7 | for full description] |
| 8 | .SH DESCRIPTION |
| 9 | The |
| 10 | .I zlib |
| 11 | library is a general purpose data compression library. |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 12 | The code is thread safe, assuming that the standard library functions |
| 13 | used are thread safe, such as memory allocation routines. |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 14 | It provides in-memory compression and decompression functions, |
| 15 | including integrity checks of the uncompressed data. |
| 16 | This version of the library supports only one compression method (deflation) |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 17 | but other algorithms may be added later |
| 18 | with the same stream interface. |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 19 | .LP |
| 20 | Compression can be done in a single step if the buffers are large enough |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 21 | or can be done by repeated calls of the compression function. |
| 22 | In the latter case, |
| 23 | the application must provide more input and/or consume the output |
| 24 | (providing more output space) before each call. |
| 25 | .LP |
| 26 | The library also supports reading and writing files in |
| 27 | .IR gzip (1) |
| 28 | (.gz) format |
| 29 | with an interface similar to that of stdio. |
| 30 | .LP |
| 31 | The library does not install any signal handler. |
| 32 | The decoder checks the consistency of the compressed data, |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 33 | so the library should never crash even in the case of corrupted input. |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 34 | .LP |
| 35 | All functions of the compression library are documented in the file |
| 36 | .IR zlib.h . |
| 37 | The distribution source includes examples of use of the library |
| 38 | in the files |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 39 | .I test/example.c |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 40 | and |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 41 | .IR test/minigzip.c, |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 42 | as well as other examples in the |
| 43 | .IR examples/ |
| 44 | directory. |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 45 | .LP |
| 46 | Changes to this version are documented in the file |
| 47 | .I ChangeLog |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 48 | that accompanies the source. |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 49 | .LP |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 50 | .I zlib |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 51 | is available in Java using the java.util.zip package: |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 52 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 53 | http://java.sun.com/developer/technicalArticles/Programming/compression/ |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 54 | .LP |
| 55 | A Perl interface to |
| 56 | .IR zlib , |
| 57 | written by Paul Marquess (pmqs@cpan.org), |
| 58 | is available at CPAN (Comprehensive Perl Archive Network) sites, |
| 59 | including: |
| 60 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 61 | http://search.cpan.org/~pmqs/IO-Compress-Zlib/ |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 62 | .LP |
| 63 | A Python interface to |
| 64 | .IR zlib , |
| 65 | written by A.M. Kuchling (amk@magnet.com), |
| 66 | is available in Python 1.5 and later versions: |
| 67 | .IP |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 68 | http://docs.python.org/library/zlib.html |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 69 | .LP |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 70 | .I zlib |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 71 | is built into |
| 72 | .IR tcl: |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 73 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 74 | http://wiki.tcl.tk/4610 |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 75 | .LP |
| 76 | An experimental package to read and write files in .zip format, |
| 77 | written on top of |
| 78 | .I zlib |
| 79 | by Gilles Vollant (info@winimage.com), |
| 80 | is available at: |
| 81 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 82 | http://www.winimage.com/zLibDll/minizip.html |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 83 | and also in the |
| 84 | .I contrib/minizip |
| 85 | directory of the main |
| 86 | .I zlib |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 87 | source distribution. |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 88 | .SH "SEE ALSO" |
| 89 | The |
| 90 | .I zlib |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 91 | web site can be found at: |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 92 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 93 | http://zlib.net/ |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 94 | .LP |
| 95 | The data format used by the zlib library is described by RFC |
| 96 | (Request for Comments) 1950 to 1952 in the files: |
| 97 | .IP |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 98 | http://tools.ietf.org/html/rfc1950 (for the zlib header and trailer format) |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 99 | .br |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 100 | http://tools.ietf.org/html/rfc1951 (for the deflate compressed data format) |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 101 | .br |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 102 | http://tools.ietf.org/html/rfc1952 (for the gzip header and trailer format) |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 103 | .LP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 104 | Mark Nelson wrote an article about |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 105 | .I zlib |
| 106 | for the Jan. 1997 issue of Dr. Dobb's Journal; |
| 107 | a copy of the article is available at: |
| 108 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 109 | http://marknelson.us/1997/01/01/zlib-engine/ |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 110 | .SH "REPORTING PROBLEMS" |
| 111 | Before reporting a problem, |
| 112 | please check the |
| 113 | .I zlib |
| 114 | web site to verify that you have the latest version of |
| 115 | .IR zlib ; |
| 116 | otherwise, |
| 117 | obtain the latest version and see if the problem still exists. |
| 118 | Please read the |
| 119 | .I zlib |
| 120 | FAQ at: |
| 121 | .IP |
Elliott Hughes | 381716e | 2010-04-19 17:17:14 -0700 | [diff] [blame] | 122 | http://zlib.net/zlib_faq.html |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 123 | .LP |
| 124 | before asking for help. |
| 125 | Send questions and/or comments to zlib@gzip.org, |
| 126 | or (for the Windows DLL version) to Gilles Vollant (info@winimage.com). |
| 127 | .SH AUTHORS |
Elliott Hughes | ee9e11d | 2012-01-31 11:31:13 -0800 | [diff] [blame^] | 128 | Version 1.2.6 |
| 129 | Copyright (C) 1995-2012 Jean-loup Gailly (jloup@gzip.org) |
The Android Open Source Project | 9e38dfa | 2009-03-03 19:31:38 -0800 | [diff] [blame] | 130 | and Mark Adler (madler@alumni.caltech.edu). |
| 131 | .LP |
| 132 | This software is provided "as-is," |
| 133 | without any express or implied warranty. |
| 134 | In no event will the authors be held liable for any damages |
| 135 | arising from the use of this software. |
| 136 | See the distribution directory with respect to requirements |
| 137 | governing redistribution. |
| 138 | The deflate format used by |
| 139 | .I zlib |
| 140 | was defined by Phil Katz. |
| 141 | The deflate and |
| 142 | .I zlib |
| 143 | specifications were written by L. Peter Deutsch. |
| 144 | Thanks to all the people who reported problems and suggested various |
| 145 | improvements in |
| 146 | .IR zlib ; |
| 147 | who are too numerous to cite here. |
| 148 | .LP |
| 149 | UNIX manual page by R. P. C. Rodgers, |
| 150 | U.S. National Library of Medicine (rodgers@nlm.nih.gov). |
| 151 | .\" end of man page |