FAQ (205194) | FAQ (230837) |
---|---|
1 2 Frequently Asked Questions about zlib 3 4 5If your question is not there, please check the zlib home page 6http://zlib.net/ which may have more recent information. 7The lastest zlib FAQ is at http://zlib.net/zlib_faq.html 8 --- 30 unchanged lines hidden (view full) --- 39 made with more input or output space. A Z_BUF_ERROR may in fact be 40 unavoidable depending on how the functions are used, since it is not 41 possible to tell whether or not there is more output pending when 42 strm.avail_out returns with zero. See http://zlib.net/zlib_how.html for a 43 heavily annotated example. 44 45 6. Where's the zlib documentation (man pages, etc.)? 46 | 1 2 Frequently Asked Questions about zlib 3 4 5If your question is not there, please check the zlib home page 6http://zlib.net/ which may have more recent information. 7The lastest zlib FAQ is at http://zlib.net/zlib_faq.html 8 --- 30 unchanged lines hidden (view full) --- 39 made with more input or output space. A Z_BUF_ERROR may in fact be 40 unavoidable depending on how the functions are used, since it is not 41 possible to tell whether or not there is more output pending when 42 strm.avail_out returns with zero. See http://zlib.net/zlib_how.html for a 43 heavily annotated example. 44 45 6. Where's the zlib documentation (man pages, etc.)? 46 |
47 It's in zlib.h . Examples of zlib usage are in the files example.c and 48 minigzip.c, with more in examples/ . | 47 It's in zlib.h . Examples of zlib usage are in the files test/example.c 48 and test/minigzip.c, with more in examples/ . |
49 50 7. Why don't you use GNU autoconf or libtool or ...? 51 52 Because we would like to keep zlib as a very small and simple package. 53 zlib is rather portable and doesn't need much configuration. 54 55 8. I found a bug in zlib. 56 --- 22 unchanged lines hidden (view full) --- 79 8012. Can zlib handle .Z files? 81 82 No, sorry. You have to spawn an uncompress or gunzip subprocess, or adapt 83 the code of uncompress on your own. 84 8513. How can I make a Unix shared library? 86 | 49 50 7. Why don't you use GNU autoconf or libtool or ...? 51 52 Because we would like to keep zlib as a very small and simple package. 53 zlib is rather portable and doesn't need much configuration. 54 55 8. I found a bug in zlib. 56 --- 22 unchanged lines hidden (view full) --- 79 8012. Can zlib handle .Z files? 81 82 No, sorry. You have to spawn an uncompress or gunzip subprocess, or adapt 83 the code of uncompress on your own. 84 8513. How can I make a Unix shared library? 86 |
87 make clean 88 ./configure -s | 87 By default a shared (and a static) library is built for Unix. So: 88 89 make distclean 90 ./configure |
89 make 90 9114. How do I install a shared zlib library on Unix? 92 93 After the above, then: 94 95 make install 96 --- 223 unchanged lines hidden (view full) --- 32039. What's the difference between the "gzip" and "deflate" HTTP 1.1 encodings? 321 322 "gzip" is the gzip format, and "deflate" is the zlib format. They should 323 probably have called the second one "zlib" instead to avoid confusion with 324 the raw deflate compressed data format. While the HTTP 1.1 RFC 2616 325 correctly points to the zlib specification in RFC 1950 for the "deflate" 326 transfer encoding, there have been reports of servers and browsers that 327 incorrectly produce or expect raw deflate data per the deflate | 91 make 92 9314. How do I install a shared zlib library on Unix? 94 95 After the above, then: 96 97 make install 98 --- 223 unchanged lines hidden (view full) --- 32239. What's the difference between the "gzip" and "deflate" HTTP 1.1 encodings? 323 324 "gzip" is the gzip format, and "deflate" is the zlib format. They should 325 probably have called the second one "zlib" instead to avoid confusion with 326 the raw deflate compressed data format. While the HTTP 1.1 RFC 2616 327 correctly points to the zlib specification in RFC 1950 for the "deflate" 328 transfer encoding, there have been reports of servers and browsers that 329 incorrectly produce or expect raw deflate data per the deflate |
328 specficiation in RFC 1951, most notably Microsoft. So even though the | 330 specification in RFC 1951, most notably Microsoft. So even though the |
329 "deflate" transfer encoding using the zlib format would be the more 330 efficient approach (and in fact exactly what the zlib format was designed 331 for), using the "gzip" transfer encoding is probably more reliable due to 332 an unfortunate choice of name on the part of the HTTP 1.1 authors. 333 334 Bottom line: use the gzip format for HTTP 1.1 encoding. 335 33640. Does zlib support the new "Deflate64" format introduced by PKWare? --- 30 unchanged lines hidden --- | 331 "deflate" transfer encoding using the zlib format would be the more 332 efficient approach (and in fact exactly what the zlib format was designed 333 for), using the "gzip" transfer encoding is probably more reliable due to 334 an unfortunate choice of name on the part of the HTTP 1.1 authors. 335 336 Bottom line: use the gzip format for HTTP 1.1 encoding. 337 33840. Does zlib support the new "Deflate64" format introduced by PKWare? --- 30 unchanged lines hidden --- |