Skip to content

Commit

Permalink
Move example.c and minigzip.c to examples/ directory.
Browse files Browse the repository at this point in the history
  • Loading branch information
madler committed Oct 9, 2011
1 parent 77b47d5 commit 1bd2fa1
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 9 deletions.
8 changes: 3 additions & 5 deletions INDEX
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,8 @@ uncompr.c
zutil.c
zutil.h

source files for sample programs:
example.c
minigzip.c
See examples/README.examples for more
source files for sample programs
See examples/README.examples

unsupported contribution by third parties
unsupported contributions by third parties
See contrib/README.contrib
14 changes: 10 additions & 4 deletions Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,17 @@ match.lo: match.S
mv _match.o match.lo
rm -f _match.s

example64.o: example.c zlib.h zconf.h
$(CC) $(CFLAGS) -D_FILE_OFFSET_BITS=64 -c -o $@ example.c
example.o: examples/example.c zlib.h zconf.h
$(CC) $(CFLAGS) -I. -c -o $@ examples/example.c

minigzip64.o: minigzip.c zlib.h zconf.h
$(CC) $(CFLAGS) -D_FILE_OFFSET_BITS=64 -c -o $@ minigzip.c
minigzip.o: examples/minigzip.c zlib.h zconf.h
$(CC) $(CFLAGS) -I. -c -o $@ examples/minigzip.c

example64.o: examples/example.c zlib.h zconf.h
$(CC) $(CFLAGS) -I. -D_FILE_OFFSET_BITS=64 -c -o $@ examples/example.c

minigzip64.o: examples/minigzip.c zlib.h zconf.h
$(CC) $(CFLAGS) -I. -D_FILE_OFFSET_BITS=64 -c -o $@ examples/minigzip.c

.SUFFIXES: .lo

Expand Down
9 changes: 9 additions & 0 deletions examples/README.examples
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ enough.c
- calculates the maximum table space used in inflate tree
construction over all possible Huffman codes

example.c
usage examples of zlib
- used in zlib build Makefile for testing

fitblk.c
compress just enough input to nearly fill a requested output size
- zlib isn't designed to do this, but fitblk does it anyway
Expand Down Expand Up @@ -34,6 +38,11 @@ gzlog.h
and deflateSetDictionary()
- illustrates use of a gzip header extra field

minigzip.c
minimal implementation of gzip-like functionality using zlib
- used in zlib build Makefile for testing
- is not meant for and should not be used as a gzip replacement

zlib_how.html
painfully comprehensive description of zpipe.c (see below)
- describes in excruciating detail the use of deflate() and inflate()
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit 1bd2fa1

Please sign in to comment.