| 1 |
<html> <head> |
| 2 |
<title>Gzstream Library Home Page</title> |
| 3 |
</head> |
| 4 |
<body BGCOLOR="FAF8E8" TEXT="#000000"> |
| 5 |
|
| 6 |
<h1>Gzstream Library Home Page</h1> |
| 7 |
|
| 8 |
<hr> |
| 9 |
<TABLE><TR><TD ALIGN=LEFT VALIGN=TOP> |
| 10 |
<img border=0 src="logo.gif" align=center> |
| 11 |
</TD><TD ALIGN=LEFT VALIGN=TOP NOWRAP> |
| 12 |
<ul> |
| 13 |
<li><a href="#intro"> Introduction</a> |
| 14 |
<li><a href="#sys"> Supported Systems</a> |
| 15 |
<li><a href="#inst"> Installation</a> |
| 16 |
<li><a href="#doc"> Documentation</a> |
| 17 |
<li><a href="#miss"> What's Missing</a> |
| 18 |
<li><a href="#src"> Download</a> |
| 19 |
<li><a href="#links"> Links</a><P> |
| 20 |
</ul> |
| 21 |
</TD></TR></TABLE> |
| 22 |
|
| 23 |
|
| 24 |
<hr><!--------------------------------------------------------------------> |
| 25 |
<a name="intro"><h2> Introduction </h2></a> |
| 26 |
|
| 27 |
<i>Gzstream</i> is a small C++ library, basically just a wrapper, |
| 28 |
that provides the functionality of the |
| 29 |
<a href="http://www.gzip.org/zlib/">zlib C-library</a> in a C++ iostream. |
| 30 |
It is freely available under the <a href="COPYING.LIB">LGPL license</a>.<P> |
| 31 |
|
| 32 |
Gzstream has been written by |
| 33 |
<a href="http://www.cs.unc.edu/~debug/">Deepak Bandyopadhyay</a> and |
| 34 |
<a href="http://www.cs.unc.edu/~kettner/">Lutz Kettner</a> at |
| 35 |
the <a href="http://www.cs.unc.edu/Research/compgeom/">Computational |
| 36 |
Geometry Group at UNC Chapel Hill</a>.<P> |
| 37 |
|
| 38 |
|
| 39 |
<hr><!--------------------------------------------------------------------> |
| 40 |
<a name="sys"><h2> Supported Systems </h2></a> |
| 41 |
|
| 42 |
Gzstream requires a standard compliant C++ compiler (we use the new |
| 43 |
header file conventions and the new iostream in the std:: name space) |
| 44 |
and, of course, zlib. We used zlib 1.1.3 so far, but see the <a |
| 45 |
href="http://www.gzip.org/zlib/">zlib home page</a> for why you should |
| 46 |
upgrade to zlib 1.1.4. So, in theory, the provided sources could run |
| 47 |
on many platforms. However, we used only the following few |
| 48 |
platforms.<P> |
| 49 |
<P> |
| 50 |
|
| 51 |
<ul> |
| 52 |
<li> PC Linux, RedHat 6.1, g++ version 2.95.2 |
| 53 |
<li> PC Linux, Debian, g++ version 2.95.2 and 3.1 |
| 54 |
<li> SGI Irix 6.5, MIPSpro CC version 7.30 |
| 55 |
</ul><P> |
| 56 |
|
| 57 |
|
| 58 |
<hr><!--------------------------------------------------------------------> |
| 59 |
<a name="inst"><h2> Installation </h2></a> |
| 60 |
|
| 61 |
Either compile <tt>gzstream.C</tt> by hand, place it in some library, |
| 62 |
and move <tt>gzstream.h</tt> into the include search path of your |
| 63 |
compiler. Or use the provided <tt>Makefile</tt>, adapt its |
| 64 |
variables, and follow the remarks in the <tt>Makefile</tt>. Two |
| 65 |
test programs are provided, <tt>test_gzip.C</tt> and <tt>test_gunzip.C</tt>. |
| 66 |
The <tt>Makefile</tt> contains a rule that performs a small test |
| 67 |
with these programs.<P> |
| 68 |
|
| 69 |
|
| 70 |
<hr><!--------------------------------------------------------------------> |
| 71 |
<a name="doc"><h2> Documentation </h2></a> |
| 72 |
|
| 73 |
The library provides two classes, <tt>igzstream</tt> and <tt>ogzstream</tt>, |
| 74 |
that can be used analogously to <tt>ifstream</tt> and <tt>ofstream</tt> |
| 75 |
respectively.<P> |
| 76 |
|
| 77 |
The classes are by default in the global name space. This can |
| 78 |
be changed by setting the macro <tt>GZSTREAM_NAMESPACE</tt> to |
| 79 |
the desired name space, e.g., by setting the option |
| 80 |
</tt>-DGZSTREAM_NAMESPACE=gz</tt> in the <tt>Makefile</tt>. |
| 81 |
However, this needs to be consistent for both, the library compilation |
| 82 |
and the application that uses the library.<P> |
| 83 |
|
| 84 |
|
| 85 |
<hr><!--------------------------------------------------------------------> |
| 86 |
<a name="miss"><h2> What's Missing </h2></a> |
| 87 |
|
| 88 |
<ul> |
| 89 |
<li> Seek. The zlib library provides the necessary functionality, |
| 90 |
but we have not realized that in the wrapper (yet? ;-). |
| 91 |
<li> Both streams are based on the same streambuffer. So, they |
| 92 |
cannot be used to derive an iogzstream class that would allow |
| 93 |
simultaneous reading and writing to the same file. |
| 94 |
</ul><P> |
| 95 |
|
| 96 |
|
| 97 |
<hr><!--------------------------------------------------------------------> |
| 98 |
<a name="src"><h2> Download and Release Notes</h2></a> |
| 99 |
|
| 100 |
<ul> |
| 101 |
<li> Gzstream library 1.5 (08 Apr 2003): |
| 102 |
<a href="gzstream.tgz">gzstream.tgz</a><br> |
| 103 |
Fixed bug that did not set the state correctly on failure to open or |
| 104 |
close a file. <br> |
| 105 |
Fixed bug in the indexing of the write buffer that |
| 106 |
caused the write buffer to shrink continously and finally caused |
| 107 |
wrong results when writing compressed files (only observed on some |
| 108 |
platforms). <P> |
| 109 |
<li> Gzstream library 1.4 (27 Apr 2002):<br> |
| 110 |
Fixed a bug that stopped stream output after calling <tt>flush()</tt> |
| 111 |
or using <tt>std::endl</tt>.<P> |
| 112 |
<li> Gzstream library 1.3 (06 Nov 2001):<br> |
| 113 |
Fixed unsigned char -- signed char bug. Increased buffer size |
| 114 |
for better performance.<P> |
| 115 |
<li> Gzstream library 1.2 (04 Oct 2001):<br> |
| 116 |
Initial release as gzstream, renamed from zipstream.<P> |
| 117 |
<li> Zipstream library 1.1 (09 Sep 2001):<br> |
| 118 |
Initial release. |
| 119 |
</ul> |
| 120 |
|
| 121 |
<hr><!--------------------------------------------------------------------> |
| 122 |
<a name="links"><h2> Acknowledgements </h2></a> |
| 123 |
|
| 124 |
Credits for finding bugs and improving this software go to: |
| 125 |
Vincent Ricard, Peter Milley, Peter J. Torelli, and Ares Lagae. |
| 126 |
<P> |
| 127 |
|
| 128 |
<hr><!--------------------------------------------------------------------> |
| 129 |
<a name="links"><h2> Links </h2></a> |
| 130 |
|
| 131 |
<ul> |
| 132 |
<li><a href="http://www.gzip.org/zlib/">zlib C-library</a> |
| 133 |
<li><a href="http://www.cs.unc.edu/~debug/">Deepak Bandyopadhyay</a> |
| 134 |
<li><a href="http://www.cs.unc.edu/~kettner/">Lutz Kettner</a> |
| 135 |
<li><a href="http://www.cs.unc.edu/Research/compgeom/"> |
| 136 |
The Computational Geometry Group at UNC Chapel Hill</a> |
| 137 |
</ul> |
| 138 |
|
| 139 |
<hr><!--------------------------------------------------------------------> |
| 140 |
<address> |
| 141 |
The Computational Geometry Group at UNC Chapel Hill, Jan. 08, 2003. |
| 142 |
</address> |
| 143 |
</body> </html> |
| 144 |
<!--------------------------------------------------------------------> |
| 145 |
<!EOF> |