Add support for zstd compression
* configure.ac (zstd): Register compression program. * doc/tar.1: Mention --zstd. * doc/tar.texi: Document zstd support. * src/buffer.c: Register zstd compression. * src/suffix.c: Add suffixes zst and tzst. * src/tar.c: New compression option --zstd.
This commit is contained in:
committed by
Sergey Poznyakoff
parent
64b43fdf70
commit
3d45373d3b
1
doc/.gitignore
vendored
1
doc/.gitignore
vendored
@@ -24,3 +24,4 @@ tar.tp
|
||||
tar.vr
|
||||
version.texi
|
||||
/parse-datetime.texi
|
||||
/rmt.8
|
||||
|
||||
@@ -831,6 +831,10 @@ Filter the archive through
|
||||
\fB\-Z\fR, \fB\-\-compress\fR, \fB\-\-uncompress\fR
|
||||
Filter the archive through
|
||||
.BR compress (1).
|
||||
.TP
|
||||
\fB\-\-zstd\fR
|
||||
Filter the archive through
|
||||
.BR zstd (1).
|
||||
.SS Local file selection
|
||||
.TP
|
||||
\fB\-\-add\-file\fR=\fIFILE\fR
|
||||
|
||||
29
doc/tar.texi
29
doc/tar.texi
@@ -3713,6 +3713,9 @@ only attributes from the user namespace.
|
||||
@itemx -J
|
||||
Use @command{xz} for compressing or decompressing the archives. @xref{gzip}.
|
||||
|
||||
@item --zstd
|
||||
Use @command{zstd} for compressing or decompressing the archives. @xref{gzip}.
|
||||
|
||||
@end table
|
||||
|
||||
@node Short Option Summary
|
||||
@@ -9520,6 +9523,7 @@ switch to @samp{posix}.
|
||||
@cindex lzma
|
||||
@cindex lzop
|
||||
@cindex compress
|
||||
@cindex zstd
|
||||
@GNUTAR{} is able to create and read compressed archives. It supports
|
||||
a wide variety of compression programs, namely: @command{gzip},
|
||||
@command{bzip2}, @command{lzip}, @command{lzma}, @command{lzop},
|
||||
@@ -9530,14 +9534,21 @@ compression programs@footnote{It also had patent problems in the past.}.
|
||||
|
||||
Creating a compressed archive is simple: you just specify a
|
||||
@dfn{compression option} along with the usual archive creation
|
||||
commands. The compression option is @option{-z} (@option{--gzip}) to
|
||||
create a @command{gzip} compressed archive, @option{-j}
|
||||
(@option{--bzip2}) to create a @command{bzip2} compressed archive,
|
||||
@option{--lzip} to create an @asis{lzip} compressed archive,
|
||||
@option{-J} (@option{--xz}) to create an @asis{XZ} archive,
|
||||
@option{--lzma} to create an @asis{LZMA} compressed
|
||||
archive, @option{--lzop} to create an @asis{LZOP} archive, and
|
||||
@option{-Z} (@option{--compress}) to use @command{compress} program.
|
||||
commands. Available compression options are summarized in the
|
||||
table below:
|
||||
|
||||
@multitable @columnfractions 0.4 0.2 0.4
|
||||
@headitem Long @tab Short @tab Archive format
|
||||
@item @option{--gzip} @tab @option{-z} @tab @command{gzip}
|
||||
@item @option{--bzip2} @tab @option{-j} @tab @command{bzip2}
|
||||
@item @option{--xz} @tab @option{-J} @tab @command{xz}
|
||||
@item @option{--lzip} @tab @tab @command{lzip}
|
||||
@item @option{--lzma} @tab @tab @command{lzma}
|
||||
@item @option{--lzop} @tab @tab @command{lzop}
|
||||
@item @option{--zstd} @tab @tab @command{zstd}
|
||||
@item @option{--compress} @tab @option{-Z} @tab @command{compress}
|
||||
@end multitable
|
||||
|
||||
For example:
|
||||
|
||||
@smallexample
|
||||
@@ -9730,6 +9741,8 @@ suffix. The following suffixes are recognized:
|
||||
@item @samp{.tlz} @tab @command{lzma}
|
||||
@item @samp{.lzo} @tab @command{lzop}
|
||||
@item @samp{.xz} @tab @command{xz}
|
||||
@item @samp{.zst} @tab @command{zstd}
|
||||
@item @samp{.tzst} @tab @command{zstd}
|
||||
@end multitable
|
||||
|
||||
@anchor{use-compress-program}
|
||||
|
||||
Reference in New Issue
Block a user