Permalink
Browse files

pigz 2.3.1

  • Loading branch information...
1 parent ae4aab6 commit ab4d4b251b65ee3b4a7827896b834d13436fc3c5 tls committed Jun 15, 2014
Showing with 6,244 additions and 838 deletions.
  1. +45 −15 external/zlib/pigz/dist/Makefile
  2. +5 −3 external/zlib/pigz/dist/README
  3. +30 −5 external/zlib/pigz/dist/pigz.1
  4. +1,675 −780 external/zlib/pigz/dist/pigz.c
  5. BIN external/zlib/pigz/dist/pigz.pdf
  6. +33 −26 external/zlib/pigz/dist/pigz.spec
  7. +14 −4 external/zlib/pigz/dist/yarn.c
  8. +5 −5 external/zlib/pigz/dist/yarn.h
  9. +6 −0 external/zlib/pigz/dist/zopfli/CONTRIBUTORS
  10. +201 −0 external/zlib/pigz/dist/zopfli/COPYING
  11. +24 −0 external/zlib/pigz/dist/zopfli/README
  12. +344 −0 external/zlib/pigz/dist/zopfli/blocksplitter.c
  13. +77 −0 external/zlib/pigz/dist/zopfli/blocksplitter.h
  14. +119 −0 external/zlib/pigz/dist/zopfli/cache.c
  15. +66 −0 external/zlib/pigz/dist/zopfli/cache.h
  16. +705 −0 external/zlib/pigz/dist/zopfli/deflate.c
  17. +77 −0 external/zlib/pigz/dist/zopfli/deflate.h
  18. +117 −0 external/zlib/pigz/dist/zopfli/gzip_container.c
  19. +42 −0 external/zlib/pigz/dist/zopfli/gzip_container.h
  20. +135 −0 external/zlib/pigz/dist/zopfli/hash.c
  21. +70 −0 external/zlib/pigz/dist/zopfli/hash.h
  22. +251 −0 external/zlib/pigz/dist/zopfli/katajainen.c
  23. +42 −0 external/zlib/pigz/dist/zopfli/katajainen.h
  24. +468 −0 external/zlib/pigz/dist/zopfli/lz77.c
  25. +126 −0 external/zlib/pigz/dist/zopfli/lz77.h
  26. +5 −0 external/zlib/pigz/dist/zopfli/makefile
  27. +543 −0 external/zlib/pigz/dist/zopfli/squeeze.c
  28. +60 −0 external/zlib/pigz/dist/zopfli/squeeze.h
  29. +101 −0 external/zlib/pigz/dist/zopfli/tree.c
  30. +51 −0 external/zlib/pigz/dist/zopfli/tree.h
  31. +202 −0 external/zlib/pigz/dist/zopfli/util.c
  32. +175 −0 external/zlib/pigz/dist/zopfli/util.h
  33. +79 −0 external/zlib/pigz/dist/zopfli/zlib_container.c
  34. +42 −0 external/zlib/pigz/dist/zopfli/zlib_container.h
  35. +71 −0 external/zlib/pigz/dist/zopfli/zopfli.h
  36. +204 −0 external/zlib/pigz/dist/zopfli/zopfli_bin.c
  37. +34 −0 external/zlib/pigz/dist/zopfli/zopfli_lib.c
@@ -1,47 +1,77 @@
-CFLAGS=-O3
+CC=cc
+CFLAGS=-O3 -Wall -Wextra
-pigz: pigz.o yarn.o
- cc -o pigz pigz.o yarn.o -lpthread -lz
+
+pigz: pigz.o yarn.o zopfli/deflate.o zopfli/blocksplitter.o zopfli/tree.o zopfli/lz77.o zopfli/cache.o zopfli/hash.o zopfli/util.o zopfli/squeeze.o zopfli/katajainen.o
+ $(CC) $(LDFLAGS) -o pigz $^ -lpthread -lz -lm
ln -f pigz unpigz
-pigz.o: pigz.c yarn.h
+pigz.o: pigz.c yarn.h zopfli/deflate.h zopfli/util.h
yarn.o: yarn.c yarn.h
+zopfli/deflate.o: zopfli/deflate.c zopfli/deflate.h zopfli/blocksplitter.h zopfli/lz77.h zopfli/squeeze.h zopfli/tree.h zopfli/zopfli.h zopfli/cache.h zopfli/hash.h zopfli/util.h
+
+zopfli/blocksplitter.o: zopfli/blocksplitter.c zopfli/blocksplitter.h zopfli/deflate.h zopfli/lz77.h zopfli/squeeze.h zopfli/tree.h zopfli/util.h zopfli/zopfli.h zopfli/cache.h zopfli/hash.h
+
+zopfli/tree.o: zopfli/tree.c zopfli/tree.h zopfli/katajainen.h zopfli/util.h
+
+zopfli/lz77.o: zopfli/lz77.h zopfli/util.h zopfli/cache.h zopfli/hash.h zopfli/zopfli.h
+
+zopfli/cache.o: zopfli/cache.c zopfli/cache.h zopfli/util.h
+
+zopfli/hash.o: zopfli/hash.c zopfli/hash.h zopfli/util.h
+
+zopfli/util.o: zopfli/util.c zopfli/util.h
+
+zopfli/squeeze.o: zopfli/squeeze.c zopfli/squeeze.h zopfli/blocksplitter.h zopfli/deflate.h zopfli/tree.h zopfli/util.h zopfli/zopfli.h zopfli/lz77.h zopfli/cache.h zopfli/hash.h
+
+zopfli/katajainen.o: zopfli/katajainen.c zopfli/katajainen.h
+
dev: pigz pigzt pigzn
-pigzt: pigzt.o yarnt.o
- cc -o pigzt pigzt.o yarnt.o -lpthread -lz
+pigzt: pigzt.o yarnt.o zopfli/deflate.o zopfli/blocksplitter.o zopfli/tree.o zopfli/lz77.o zopfli/cache.o zopfli/hash.o zopfli/util.o zopfli/squeeze.o zopfli/katajainen.o
+ $(CC) $(LDFLAGS) -o pigzt $^ -lpthread -lz -lm
pigzt.o: pigz.c yarn.h
- cc -Wall -O3 -DDEBUG -g -c -o pigzt.o pigz.c
+ $(CC) $(CFLAGS) -DDEBUG -g -c -o pigzt.o pigz.c
yarnt.o: yarn.c yarn.h
- cc -Wall -O3 -DDEBUG -g -c -o yarnt.o yarn.c
+ $(CC) $(CFLAGS) -DDEBUG -g -c -o yarnt.o yarn.c
-pigzn: pigzn.o
- cc -o pigzn pigzn.o -lz
+pigzn: pigzn.o zopfli/deflate.o zopfli/blocksplitter.o zopfli/tree.o zopfli/lz77.o zopfli/cache.o zopfli/hash.o zopfli/util.o zopfli/squeeze.o zopfli/katajainen.o
+ $(CC) $(LDFLAGS) -o pigzn $^ -lz -lm
pigzn.o: pigz.c
- cc -Wall -O3 -DDEBUG -DNOTHREAD -g -c -o pigzn.o pigz.c
+ $(CC) $(CFLAGS) -DDEBUG -DNOTHREAD -g -c -o pigzn.o pigz.c
test: pigz
./pigz -kf pigz.c ; ./pigz -t pigz.c.gz
./pigz -kfb 32 pigz.c ; ./pigz -t pigz.c.gz
./pigz -kfp 1 pigz.c ; ./pigz -t pigz.c.gz
./pigz -kfz pigz.c ; ./pigz -t pigz.c.zz
./pigz -kfK pigz.c ; ./pigz -t pigz.c.zip
- compress -f < pigz.c | ./unpigz | cmp - pigz.c
- rm -f pigz.c.gz pigz.c.zz pigz.c.zip
+ printf "" | ./pigz -cdf | wc -c | test `cat` -eq 0
+ printf "x" | ./pigz -cdf | wc -c | test `cat` -eq 1
+ printf "xy" | ./pigz -cdf | wc -c | test `cat` -eq 2
+ printf "xyz" | ./pigz -cdf | wc -c | test `cat` -eq 3
+ (printf "w" | gzip ; printf "x") | ./pigz -cdf | wc -c | test `cat` -eq 2
+ (printf "w" | gzip ; printf "xy") | ./pigz -cdf | wc -c | test `cat` -eq 3
+ (printf "w" | gzip ; printf "xyz") | ./pigz -cdf | wc -c | test `cat` -eq 4
+ -@if test "`whereis compress | grep /`" != ""; then \
+ echo 'compress -f < pigz.c | ./unpigz | cmp - pigz.c' ;\
+ compress -f < pigz.c | ./unpigz | cmp - pigz.c ;\
+ fi
+ @rm -f pigz.c.gz pigz.c.zz pigz.c.zip
tests: dev test
./pigzn -kf pigz.c ; ./pigz -t pigz.c.gz
- rm -f pigz.c.gz
+ @rm -f pigz.c.gz
docs: pigz.pdf
pigz.pdf: pigz.1
groff -mandoc -f H -T ps pigz.1 | ps2pdf - pigz.pdf
clean:
- rm -f *.o pigz unpigz pigzn pigzt pigz.c.gz pigz.c.zz pigz.c.zip
+ @rm -f *.o zopfli/*.o pigz unpigz pigzn pigzt pigz.c.gz pigz.c.zz pigz.c.zip
@@ -1,4 +1,4 @@
-pigz 2.1.6 (17 Jan 2010) by Mark Adler
+pigz 2.3.1 (9 Oct 2013) by Mark Adler
pigz, which stands for Parallel Implementation of GZip, is a fully functional
replacement for gzip that exploits multiple processors and multiple cores to
@@ -14,8 +14,10 @@ install the executable wherever you like in your path (e.g. /usr/local/bin/).
Type "pigz" to see the command help and all of the command options.
The latest version of pigz can be found at http://zlib.net/pigz/ . You need
-zlib version 1.2.3 or later to compile pigz. You can find the latest version
-of zlib at http://zlib.net/ . You can look in pigz.c for the change history.
+zlib version 1.2.3 or later to compile pigz. zlib version 1.2.6 or later is
+recommended, which reduces the overhead between blocks. You can find the
+latest version of zlib at http://zlib.net/ . You can look in pigz.c for the
+change history.
Questions, comments, bug reports, fixes, etc. can be emailed to Mark at his
address in the license below.
@@ -4,7 +4,7 @@ pigz, unpigz \- compress or expand files
.SH SYNOPSIS
.ll +8
.B pigz
-.RB [ " \-cdfhikKlLnNqrRtTz0..9 " ]
+.RB [ " \-cdfhikKlLnNqrRtTz0..9,11 " ]
[
.B -b
.I blocksize
@@ -63,7 +63,7 @@ The default input block size is 128K, but can be changed with the
.B -b
option. The number of compress threads is set by default to the number
of online processors,
-which can be changed using the
+which can be changed using the
.B -p
option. Specifying
.B -p 1
@@ -86,7 +86,7 @@ uses a single thread
(the main thread) for decompression, but will create three other threads for
reading, writing, and check calculation, which can speed up decompression
under some circumstances. Parallel decompression can be turned off by
-specifying one process
+specifying one process
(
.B -dp 1
or
@@ -113,7 +113,12 @@ and
or
.B \-\-best
indicates the slowest compression method (best compression).
-Level 0 is no compression.
+.B -0
+is no compression.
+.B \-11
+gives a few percent better compression at a severe cost in execution time.
+The default is
+.B \-6.
.TP
.B -b --blocksize mmm
Set compression block size to mmmK (default 128KiB).
@@ -162,6 +167,9 @@ Print no messages, even on error.
.B -r --recursive
Process the contents of all subdirectories.
.TP
+.B -R --rsyncable
+Input-determined block locations for rsync.
+.TP
.B -S --suffix .sss
Use suffix .sss instead of .gz (for compression).
.TP
@@ -179,9 +187,26 @@ Show the version of pigz.
.TP
.B -z --zlib
Compress to zlib (.zz) instead of gzip format.
+.TP
+.B --
+All arguments after "--" are treated as file names (for names that start with "-")
+.TP
+These options are unique to the -11 compression level:
+.TP
+.B -F --first
+Do iterations first, before block split (default is last).
+.TP
+.B -I, --iterations n
+Number of iterations for optimization (default 15).
+.TP
+.B -M, --maxsplits n
+Maximum number of split blocks (default 15).
+.TP
+.B -O --oneblock
+Do not split into smaller blocks (default is block splitting).
.SH "COPYRIGHT NOTICE"
This software is provided 'as-is', without any express or implied
warranty. In no event will the author be held liable for any damages
arising from the use of this software.
.PP
-Copyright (C) 2007, 2008, 2009, 2010 Mark Adler <madler@alumni.caltech.edu>
+Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Mark Adler <madler@alumni.caltech.edu>
Oops, something went wrong.

0 comments on commit ab4d4b2

Please sign in to comment.