Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/keithj/deoxybyte-gzip
Common Lisp interface to zlib via CFFI.
https://github.com/keithj/deoxybyte-gzip
Last synced: 2 days ago
JSON representation
Common Lisp interface to zlib via CFFI.
- Host: GitHub
- URL: https://github.com/keithj/deoxybyte-gzip
- Owner: keithj
- License: gpl-3.0
- Created: 2009-11-17T23:51:17.000Z (about 15 years ago)
- Default Branch: devel
- Last Pushed: 2024-12-26T17:36:55.000Z (about 1 month ago)
- Last Synced: 2024-12-26T18:28:05.979Z (about 1 month ago)
- Language: Common Lisp
- Homepage:
- Size: 289 KB
- Stars: 5
- Watchers: 3
- Forks: 4
- Open Issues: 1
-
Metadata Files:
- Readme: README.txt
- License: LICENSE.txt
Awesome Lists containing this project
- trackawesomelist - deoxybyte-gzip (⭐7) - Common Lisp interface to zlib via CFFI. GPL3. (Recently Updated / [Who Wants to Be a Millionare](https://www.boardgamecapital.com/who-wants-to-be-a-millionaire-rules.htm))
README
Introduction
This system provides gzip and gunzip functions and a Gray-streams
implementation, both built on a set of lower-level zlib functions.Functions are provided for inflating and deflating to and from Lisp
octet vectors and Lisp octet streams, which may be tuned using the
Zlib tuning parameters described in the Zlib C function deflateInit2.In addition, a basic implementation of the data structure described in
RFC1952 is included, allowing a hybrid approach to reading gzip data,
using native Lisp streams and Zlib inflate/deflate.Measuring execution times of the gz:gzip and gz:gunzip functions shows
deoxybyte-gzip to be fractionally slower than gzip, but over 3x slower
than gunzip.Relative execution time (SBCL 1.0.40 X86-64):
gzip deoxybyte-gzip gzip-stream
Compression 1.0 1.1 1.1
Decompression 1.0 3.1 3.5Timings were taken compressing and decompressing a 1.8 Gb text file
using gzip/gunzip command line programs, the gz:gzip/gz:gunzip
functions (which use an internal buffer of length 2^16 -1) and the
Gray streams classes using
gz:stream-read-sequence/gz:stream-write-sequence methods. A zlib
compression level of 6 was used.This system is named with a deoxybyte- prefix because there are
several existing Common Lisp packages using the gzip name and I don't
want to clash with them.Installation
deoxybyte-gzip uses ASDF for system definition. Copy or symlink
deoxybyte-gzip.asd (and optionally deoxybyte-gzip-test.asd) to your
asdf:*central-registry* and load deoxybyte-io with the asdf:operate
function:(asdf:operate 'asdf:load-op :deoxybyte-gzip)
or with the equivalent deoxybyte-systems:load-system function:
(dxs:load-system :deoxybyte-gzip)
Tests
To run the unit and regression tests you need to have LIFT
installed. Run the tests with the asdf:operate function:(asdf:operate 'asdf:test-op :deoxybyte-gzip)
or with the equivalent deoxybyte-systems:test-system function:
(dxs:test-system :deoxybyte-gzip)
Documentation
See the Lisp docstrings, particularly the package docstrings for an
overview. HTML documentation may be generated with the command:(dxs:document-system :deoxybyte-gzip)
at the REPL, provided that CLDOC is installed.
Dependencies
deoxybyte-systems git://github.com/keithj/deoxybyte-systems.git
deoxybyte-io git://github.com/keithj/deoxybyte-io.gitOptional dependencies
LIFT http://common-lisp.net/project/lift/
CLDOC http://common-lisp.net/project/cldoc/