Page 1 of 1

Utilities to manipulate Compressed Files

PostPosted: Tue Jul 15, 2014 3:11 am
by samsam598
Greetings,

Would like to know whether any utils over there to read/write zip/7z/rar format files?

Thanks for the help in advance.

Re: Utilities to manipulate Compressed Files

PostPosted: Mon Aug 18, 2014 10:15 am
by jerome
Hi Sam,

Yet another forum post that I didn't notice... Sorry.

The goal is that this would be handled by the Ecere File and Archive class.
FileOpen("<myArchive.zip>path/to/file.txt", read) would let you open a file within a ZIP archive whereas the Archive class will handle creating and adding to existing archives.
See ear/cmd and ear/extract for example usage.

The current reality though is that only Ecere Archives (ear) are supported at the moment.

There are libraries available however, and it'd be nice to add support through the File/Archive classes for other archives through modules.

7z: http://www.7-zip.org/sdk.html
zip: http://www.nih.at/libzip/
rar: ftp://ftp.rarlabs.com/rar/unrarsrc-3.7.8.tar.gz
gz: zlib supports that (www.zlib.net)
bz2: http://www.bzip.org/
xz: http://tukaani.org/xz/
tar: Should be simple enough to do ourselves http://en.wikipedia.org/wiki/Tar_(computing)

http://www.libarchive.org/ -- this also supports multiple archive formats

Please let me know if you'd be interested to contribute modules for this :)

Regards,

-Jerome