2

I'm looking for a C/C++ library that can open and read the contents of zipfiles (writing zipfiles isn't a strict requirement but would be nice).

I want to be able to open a file, enumerate the files and then efficient read (unencrypted) data from the files in the zipfile.

All the libraries I've found are all very WIN32 specific. I need something that can run on Mac OS X or iPhone (PPC, X86 or 64-bit).

I'm not worried about Zip64 (although again, that would be nice)

Edit: Please don't suggest zlib. Zlib is a library for compressing/decompressing zipped data. It doesn't know anything about actual zipfiles.

schwa
  • 11,962
  • 14
  • 43
  • 54
  • Duplicate: http://stackoverflow.com/questions/262899/portable-zip-library-for-c-c-not-an-application taken from http://stackoverflow.com/search?q=opensource+zip+library – dmckee --- ex-moderator kitten Feb 09 '10 at 17:23
  • 2
    I wouldn't disparage the Zlib library for only handling streams. There is code in the "contrib" folder of the Zlib source distribution that you might find useful. In particular see "contrib/minizip", which uses Zlib to handle .zip files. – bta Feb 09 '10 at 17:53

3 Answers3

2

Would this do? Minizip? Or even 7-zip?

t0mm13b
  • 34,087
  • 8
  • 78
  • 110
0

how about zlib.

bhups
  • 14,345
  • 8
  • 49
  • 57
0

Check out these guys: http://www.info-zip.org/

They make the unzip utility on linux, I'm pretty sure you could use their codebase for your projects.

static_rtti
  • 53,760
  • 47
  • 136
  • 192