QuaZIP quazip-0-7-5
QuaZIP - Qt/C++ wrapper for ZIP/UNZIP package

Overview

QuaZIP is a simple C++ wrapper over Gilles Vollant's ZIP/UNZIP package that can be used to access ZIP archives. It uses the Qt toolkit.

If you do not know what Qt is, you have two options:

The choice is yours, but if you are really interested in cross-platform (Windows/Linux/BSD/UNIX/Mac/Others) software development, I would definitely recommend you the latter ^_^

QuaZIP allows you to access files inside ZIP archives using QIODevice API, and - yes! - that means that you can also use QTextStream, QDataStream or whatever you would like to use on your zipped files.

QuaZIP provides a complete abstraction of the ZIP/UNZIP API, for both reading from and writing to ZIP archives.

Download QuaZIP

The latest downloads are available from the GitHub page.

Older downloads are available from QuaZIP project's page at SourceForge.net.

Platforms supported

QuaZIP is regularly tested on the following platforms:

It should work fine on any platform supported by Qt 4.6.2 or later. In theory, older versions might work as well, but aren't guaranteed to.

What is new in this version of QuaZIP?

See the NEWS.txt file supplied with the distribution.

Requirements

Just zlib and Qt 4/5. Sometimes you can get away with using zlib library bundled into Qt, but usually you need at least its headers to compile your project.

Building, testing and installing

Note:
Instructions given in this section assume that you are using some UNIX dialect, but the build process should be very similar on win32-g++ platform too. On other platforms it's essentially the same process, maybe with some qmake adjustments not specific to QuaZIP itself.

To build the library, run:

$ cd /wherever/quazip/source/is/quazip-x.y.z/quazip
$ qmake <qmake args> [PREFIX=where-to-install]
$ make

Make sure that you have Qt 4/5 installed with all required headers and utilities (that is, including the 'dev' or 'devel' package on Linux) and that you run qmake utility of the Qt 4/5, not some other version you may have already installed (you may need to type full path to qmake like /usr/local/qt4/bin/qmake).

To reconfigure (with another PREFIX, for example), just run

qmake distclean

and then qmake with the appropriate arguments again.

Usually, it is needed to specify additional include path or libraries in qmake args (see qmake reference in the Qt documentation). For example:

$ qmake LIBS+=-L/usr/local/zlib/lib INCLUDEPATH+=/usr/local/zlib/include

(note abscence of "-I" before the include path and the presence of "-L" before the lib path)

Also note that you may or may not need to define ZLIB_WINAPI (qmake DEFINES+=ZLIB_WINAPI) when linking to zlib on Windows, depending on how zlib was built (generally, if using zlibwapi.dll, this define is needed).

To install compiled library:

$ make install

By default, QuaZIP compiles as a DLL/SO, but you have other options:

Binary compatibility is guaranteed between minor releases starting with version 0.5, thanks to the Pimpl idiom. That is, the next binary incompatible version will be 1.x in the worst case.

Testing

To check if QuaZIP's basic features work OK on your platform, you may wish to compile the test suite provided in test directory:

$ cd /wherever/quazip/source/is/quazip-x.y.z/qztest
$ qmake
$ make
$ ./qztest

Note that the test suite looks for the quazip library in the "quazip" folder of the project ("../quazip"), but you may wish to use LIBS for some systems (Windows often puts the library in the separate "debug" or "release" directory). If you wish to use the quazip version that's already installed, provide the appropriate path.

On some systems you may need to set PATH, LD_LIBRARY_PATH or SHLIB_PATH to get "qztest" to actually run.

If everything went fine, the test suite should report a lot of PASS messages. If something goes wrong, it will provide details and a warning that some tests failed.

Using

See usage page.

Authors and contacts

This wrapper has been written by Sergei Tachenov. This is my first open source project, and it's pretty old, but it works and many people are happily using it, including myself.

If you have anything to say to me about QuaZIP library, feel free to do so (read the QuaZIP FAQ first, though). I can not promise, though, that I fix all the bugs you report in, add any features you want, or respond to your critics, or respond to your feedback at all. I may be busy, I may be tired of working on QuaZIP, I may be even dead already (you never know...).

To report bugs or to post ideas about what should be done, use GitHub. It's an awesome site, where you can report bugs or register yourself an account, fork QuaZIP (don't hesitate to do so), create a new branch, make some changes and issue a pull request, which is GitHub's way of offering patches.

Do not use e-mail to report bugs, please. Reporting bugs and problems with GitHub has that advantage that it is visible to public, and I can always search for open tickets that were created long ago. It is highly unlikely that I will search my mail for that kind of stuff, so if a bug reported by mail isn't fixed immediately, it will likely be forgotten forever.

Old bugs may still be available at SourceForge for reference.

Copyright (C) 2005-2018 Sergei Tachenov and contributors