This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
Re: ZLIB : Compress and uncompress a file
- From: Andrew Lunn <andrew at lunn dot ch>
- To: Emmanuel Coullien <coullien dot emmanuel at gmail dot com>
- Cc: ecos-discuss at ecos dot sourceware dot org
- Date: Fri, 8 Feb 2008 16:10:31 +0100
- Subject: Re: [ECOS] ZLIB : Compress and uncompress a file
- References: <3fae21000802080654x593f4d99xffb5a3f314b64552@mail.gmail.com>
On Fri, Feb 08, 2008 at 03:54:06PM +0100, Emmanuel Coullien wrote:
> Hi,
>
> Is it possible to compress / uncompress a file on a File System (RAMFS
> or JFFS) with the ZIP format using the package /services/compress/zlib
I've never tried it, but probably. You should be able to do
gzopen(path, mode)
gzread (file, buf, len)
gzclose(file)
or
gzopen(path, mode)
gzwrite (file, buf, len)
gzclose(file)
See
http://www.zlib.net/manual.html
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss