1package IO::Compress::Deflate ; 2 3require 5.006 ; 4 5use strict ; 6use warnings; 7use bytes; 8 9require Exporter ; 10 11use IO::Compress::RawDeflate 2.204 (); 12use IO::Compress::Adapter::Deflate 2.204 ; 13 14use IO::Compress::Zlib::Constants 2.204 ; 15use IO::Compress::Base::Common 2.204 qw(); 16 17 18our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, %DEFLATE_CONSTANTS, $DeflateError); 19 20$VERSION = '2.204'; 21$DeflateError = ''; 22 23@ISA = qw(IO::Compress::RawDeflate Exporter); 24@EXPORT_OK = qw( $DeflateError deflate ) ; 25%EXPORT_TAGS = %IO::Compress::RawDeflate::DEFLATE_CONSTANTS ; 26 27push @{ $EXPORT_TAGS{all} }, @EXPORT_OK ; 28Exporter::export_ok_tags('all'); 29 30 31sub new 32{ 33 my $class = shift ; 34 35 my $obj = IO::Compress::Base::Common::createSelfTiedObject($class, \$DeflateError); 36 return $obj->_create(undef, @_); 37} 38 39sub deflate 40{ 41 my $obj = IO::Compress::Base::Common::createSelfTiedObject(undef, \$DeflateError); 42 return $obj->_def(@_); 43} 44 45sub mkComp 46{ 47 my $self = shift ; 48 my $got = shift ; 49 50 my ($obj, $errstr, $errno) = IO::Compress::Adapter::Deflate::mkCompObject1( 51 $got->getValue('crc32'), 52 $got->getValue('adler32'), 53 $got->getValue('level'), 54 $got->getValue('strategy') 55 ); 56 57 return $self->saveErrorString(undef, $errstr, $errno) 58 if ! defined $obj; 59 60 return $obj; 61} 62 63 64sub mkHeader 65{ 66 my $self = shift ; 67 return ''; 68} 69 70sub mkTrailer 71{ 72 my $self = shift ; 73 return ''; 74} 75 76sub mkFinalTrailer 77{ 78 return ''; 79} 80 81sub getExtraParams 82{ 83 my $self = shift ; 84 return $self->getZlibParams(), 85} 86 87sub getInverseClass 88{ 89 no warnings 'once'; 90 return ('IO::Uncompress::Inflate', 91 \$IO::Uncompress::Inflate::InflateError); 92} 93 94sub getFileInfo 95{ 96 my $self = shift ; 97 my $params = shift; 98 my $file = shift ; 99 100} 101 102 103 1041; 105 106__END__ 107 108=head1 NAME 109 110IO::Compress::Deflate - Write RFC 1950 files/buffers 111 112=head1 SYNOPSIS 113 114 use IO::Compress::Deflate qw(deflate $DeflateError) ; 115 116 my $status = deflate $input => $output [,OPTS] 117 or die "deflate failed: $DeflateError\n"; 118 119 my $z = IO::Compress::Deflate->new( $output [,OPTS] ) 120 or die "deflate failed: $DeflateError\n"; 121 122 $z->print($string); 123 $z->printf($format, $string); 124 $z->write($string); 125 $z->syswrite($string [, $length, $offset]); 126 $z->flush(); 127 $z->tell(); 128 $z->eof(); 129 $z->seek($position, $whence); 130 $z->binmode(); 131 $z->fileno(); 132 $z->opened(); 133 $z->autoflush(); 134 $z->input_line_number(); 135 $z->newStream( [OPTS] ); 136 137 $z->deflateParams(); 138 139 $z->close() ; 140 141 $DeflateError ; 142 143 # IO::File mode 144 145 print $z $string; 146 printf $z $format, $string; 147 tell $z 148 eof $z 149 seek $z, $position, $whence 150 binmode $z 151 fileno $z 152 close $z ; 153 154=head1 DESCRIPTION 155 156This module provides a Perl interface that allows writing compressed 157data to files or buffer as defined in RFC 1950. 158 159For reading RFC 1950 files/buffers, see the companion module 160L<IO::Uncompress::Inflate|IO::Uncompress::Inflate>. 161 162=head1 Functional Interface 163 164A top-level function, C<deflate>, is provided to carry out 165"one-shot" compression between buffers and/or files. For finer 166control over the compression process, see the L</"OO Interface"> 167section. 168 169 use IO::Compress::Deflate qw(deflate $DeflateError) ; 170 171 deflate $input_filename_or_reference => $output_filename_or_reference [,OPTS] 172 or die "deflate failed: $DeflateError\n"; 173 174The functional interface needs Perl5.005 or better. 175 176=head2 deflate $input_filename_or_reference => $output_filename_or_reference [, OPTS] 177 178C<deflate> expects at least two parameters, 179C<$input_filename_or_reference> and C<$output_filename_or_reference> 180and zero or more optional parameters (see L</Optional Parameters>) 181 182=head3 The C<$input_filename_or_reference> parameter 183 184The parameter, C<$input_filename_or_reference>, is used to define the 185source of the uncompressed data. 186 187It can take one of the following forms: 188 189=over 5 190 191=item A filename 192 193If the C<$input_filename_or_reference> parameter is a simple scalar, it is 194assumed to be a filename. This file will be opened for reading and the 195input data will be read from it. 196 197=item A filehandle 198 199If the C<$input_filename_or_reference> parameter is a filehandle, the input 200data will be read from it. The string '-' can be used as an alias for 201standard input. 202 203=item A scalar reference 204 205If C<$input_filename_or_reference> is a scalar reference, the input data 206will be read from C<$$input_filename_or_reference>. 207 208=item An array reference 209 210If C<$input_filename_or_reference> is an array reference, each element in 211the array must be a filename. 212 213The input data will be read from each file in turn. 214 215The complete array will be walked to ensure that it only 216contains valid filenames before any data is compressed. 217 218=item An Input FileGlob string 219 220If C<$input_filename_or_reference> is a string that is delimited by the 221characters "<" and ">" C<deflate> will assume that it is an 222I<input fileglob string>. The input is the list of files that match the 223fileglob. 224 225See L<File::GlobMapper|File::GlobMapper> for more details. 226 227=back 228 229If the C<$input_filename_or_reference> parameter is any other type, 230C<undef> will be returned. 231 232=head3 The C<$output_filename_or_reference> parameter 233 234The parameter C<$output_filename_or_reference> is used to control the 235destination of the compressed data. This parameter can take one of 236these forms. 237 238=over 5 239 240=item A filename 241 242If the C<$output_filename_or_reference> parameter is a simple scalar, it is 243assumed to be a filename. This file will be opened for writing and the 244compressed data will be written to it. 245 246=item A filehandle 247 248If the C<$output_filename_or_reference> parameter is a filehandle, the 249compressed data will be written to it. The string '-' can be used as 250an alias for standard output. 251 252=item A scalar reference 253 254If C<$output_filename_or_reference> is a scalar reference, the 255compressed data will be stored in C<$$output_filename_or_reference>. 256 257=item An Array Reference 258 259If C<$output_filename_or_reference> is an array reference, 260the compressed data will be pushed onto the array. 261 262=item An Output FileGlob 263 264If C<$output_filename_or_reference> is a string that is delimited by the 265characters "<" and ">" C<deflate> will assume that it is an 266I<output fileglob string>. The output is the list of files that match the 267fileglob. 268 269When C<$output_filename_or_reference> is an fileglob string, 270C<$input_filename_or_reference> must also be a fileglob string. Anything 271else is an error. 272 273See L<File::GlobMapper|File::GlobMapper> for more details. 274 275=back 276 277If the C<$output_filename_or_reference> parameter is any other type, 278C<undef> will be returned. 279 280=head2 Notes 281 282When C<$input_filename_or_reference> maps to multiple files/buffers and 283C<$output_filename_or_reference> is a single 284file/buffer the input files/buffers will be stored 285in C<$output_filename_or_reference> as a concatenated series of compressed data streams. 286 287=head2 Optional Parameters 288 289The optional parameters for the one-shot function C<deflate> 290are (for the most part) identical to those used with the OO interface defined in the 291L</"Constructor Options"> section. The exceptions are listed below 292 293=over 5 294 295=item C<< AutoClose => 0|1 >> 296 297This option applies to any input or output data streams to 298C<deflate> that are filehandles. 299 300If C<AutoClose> is specified, and the value is true, it will result in all 301input and/or output filehandles being closed once C<deflate> has 302completed. 303 304This parameter defaults to 0. 305 306=item C<< BinModeIn => 0|1 >> 307 308This option is now a no-op. All files will be read in binmode. 309 310=item C<< Append => 0|1 >> 311 312The behaviour of this option is dependent on the type of output data 313stream. 314 315=over 5 316 317=item * A Buffer 318 319If C<Append> is enabled, all compressed data will be append to the end of 320the output buffer. Otherwise the output buffer will be cleared before any 321compressed data is written to it. 322 323=item * A Filename 324 325If C<Append> is enabled, the file will be opened in append mode. Otherwise 326the contents of the file, if any, will be truncated before any compressed 327data is written to it. 328 329=item * A Filehandle 330 331If C<Append> is enabled, the filehandle will be positioned to the end of 332the file via a call to C<seek> before any compressed data is 333written to it. Otherwise the file pointer will not be moved. 334 335=back 336 337When C<Append> is specified, and set to true, it will I<append> all compressed 338data to the output data stream. 339 340So when the output is a filehandle it will carry out a seek to the eof 341before writing any compressed data. If the output is a filename, it will be opened for 342appending. If the output is a buffer, all compressed data will be 343appended to the existing buffer. 344 345Conversely when C<Append> is not specified, or it is present and is set to 346false, it will operate as follows. 347 348When the output is a filename, it will truncate the contents of the file 349before writing any compressed data. If the output is a filehandle 350its position will not be changed. If the output is a buffer, it will be 351wiped before any compressed data is output. 352 353Defaults to 0. 354 355=back 356 357=head2 Examples 358 359Here are a few example that show the capabilities of the module. 360 361=head3 Streaming 362 363This very simple command line example demonstrates the streaming capabilities of the module. 364The code reads data from STDIN, compresses it, and writes the compressed data to STDOUT. 365 366 $ echo hello world | perl -MIO::Compress::Deflate=deflate -e 'deflate \*STDIN => \*STDOUT' >output.1950 367 368The special filename "-" can be used as a standin for both C<\*STDIN> and C<\*STDOUT>, 369so the above can be rewritten as 370 371 $ echo hello world | perl -MIO::Compress::Deflate=deflate -e 'deflate "-" => "-"' >output.1950 372 373=head3 Compressing a file from the filesystem 374 375To read the contents of the file C<file1.txt> and write the compressed 376data to the file C<file1.txt.1950>. 377 378 use strict ; 379 use warnings ; 380 use IO::Compress::Deflate qw(deflate $DeflateError) ; 381 382 my $input = "file1.txt"; 383 deflate $input => "$input.1950" 384 or die "deflate failed: $DeflateError\n"; 385 386=head3 Reading from a Filehandle and writing to an in-memory buffer 387 388To read from an existing Perl filehandle, C<$input>, and write the 389compressed data to a buffer, C<$buffer>. 390 391 use strict ; 392 use warnings ; 393 use IO::Compress::Deflate qw(deflate $DeflateError) ; 394 use IO::File ; 395 396 my $input = IO::File->new( "<file1.txt" ) 397 or die "Cannot open 'file1.txt': $!\n" ; 398 my $buffer ; 399 deflate $input => \$buffer 400 or die "deflate failed: $DeflateError\n"; 401 402=head3 Compressing multiple files 403 404To compress all files in the directory "/my/home" that match "*.txt" 405and store the compressed data in the same directory 406 407 use strict ; 408 use warnings ; 409 use IO::Compress::Deflate qw(deflate $DeflateError) ; 410 411 deflate '</my/home/*.txt>' => '<*.1950>' 412 or die "deflate failed: $DeflateError\n"; 413 414and if you want to compress each file one at a time, this will do the trick 415 416 use strict ; 417 use warnings ; 418 use IO::Compress::Deflate qw(deflate $DeflateError) ; 419 420 for my $input ( glob "/my/home/*.txt" ) 421 { 422 my $output = "$input.1950" ; 423 deflate $input => $output 424 or die "Error compressing '$input': $DeflateError\n"; 425 } 426 427=head1 OO Interface 428 429=head2 Constructor 430 431The format of the constructor for C<IO::Compress::Deflate> is shown below 432 433 my $z = IO::Compress::Deflate->new( $output [,OPTS] ) 434 or die "IO::Compress::Deflate failed: $DeflateError\n"; 435 436It returns an C<IO::Compress::Deflate> object on success and undef on failure. 437The variable C<$DeflateError> will contain an error message on failure. 438 439If you are running Perl 5.005 or better the object, C<$z>, returned from 440IO::Compress::Deflate can be used exactly like an L<IO::File|IO::File> filehandle. 441This means that all normal output file operations can be carried out 442with C<$z>. 443For example, to write to a compressed file/buffer you can use either of 444these forms 445 446 $z->print("hello world\n"); 447 print $z "hello world\n"; 448 449The mandatory parameter C<$output> is used to control the destination 450of the compressed data. This parameter can take one of these forms. 451 452=over 5 453 454=item A filename 455 456If the C<$output> parameter is a simple scalar, it is assumed to be a 457filename. This file will be opened for writing and the compressed data 458will be written to it. 459 460=item A filehandle 461 462If the C<$output> parameter is a filehandle, the compressed data will be 463written to it. 464The string '-' can be used as an alias for standard output. 465 466=item A scalar reference 467 468If C<$output> is a scalar reference, the compressed data will be stored 469in C<$$output>. 470 471=back 472 473If the C<$output> parameter is any other type, C<IO::Compress::Deflate>::new will 474return undef. 475 476=head2 Constructor Options 477 478C<OPTS> is any combination of zero or more the following options: 479 480=over 5 481 482=item C<< AutoClose => 0|1 >> 483 484This option is only valid when the C<$output> parameter is a filehandle. If 485specified, and the value is true, it will result in the C<$output> being 486closed once either the C<close> method is called or the C<IO::Compress::Deflate> 487object is destroyed. 488 489This parameter defaults to 0. 490 491=item C<< Append => 0|1 >> 492 493Opens C<$output> in append mode. 494 495The behaviour of this option is dependent on the type of C<$output>. 496 497=over 5 498 499=item * A Buffer 500 501If C<$output> is a buffer and C<Append> is enabled, all compressed data 502will be append to the end of C<$output>. Otherwise C<$output> will be 503cleared before any data is written to it. 504 505=item * A Filename 506 507If C<$output> is a filename and C<Append> is enabled, the file will be 508opened in append mode. Otherwise the contents of the file, if any, will be 509truncated before any compressed data is written to it. 510 511=item * A Filehandle 512 513If C<$output> is a filehandle, the file pointer will be positioned to the 514end of the file via a call to C<seek> before any compressed data is written 515to it. Otherwise the file pointer will not be moved. 516 517=back 518 519This parameter defaults to 0. 520 521=item C<< Merge => 0|1 >> 522 523This option is used to compress input data and append it to an existing 524compressed data stream in C<$output>. The end result is a single compressed 525data stream stored in C<$output>. 526 527It is a fatal error to attempt to use this option when C<$output> is not an 528RFC 1950 data stream. 529 530There are a number of other limitations with the C<Merge> option: 531 532=over 5 533 534=item 1 535 536This module needs to have been built with zlib 1.2.1 or better to work. A 537fatal error will be thrown if C<Merge> is used with an older version of 538zlib. 539 540=item 2 541 542If C<$output> is a file or a filehandle, it must be seekable. 543 544=back 545 546This parameter defaults to 0. 547 548=item -Level 549 550Defines the compression level used by zlib. The value should either be 551a number between 0 and 9 (0 means no compression and 9 is maximum 552compression), or one of the symbolic constants defined below. 553 554 Z_NO_COMPRESSION 555 Z_BEST_SPEED 556 Z_BEST_COMPRESSION 557 Z_DEFAULT_COMPRESSION 558 559The default is Z_DEFAULT_COMPRESSION. 560 561Note, these constants are not imported by C<IO::Compress::Deflate> by default. 562 563 use IO::Compress::Deflate qw(:strategy); 564 use IO::Compress::Deflate qw(:constants); 565 use IO::Compress::Deflate qw(:all); 566 567=item -Strategy 568 569Defines the strategy used to tune the compression. Use one of the symbolic 570constants defined below. 571 572 Z_FILTERED 573 Z_HUFFMAN_ONLY 574 Z_RLE 575 Z_FIXED 576 Z_DEFAULT_STRATEGY 577 578The default is Z_DEFAULT_STRATEGY. 579 580=item C<< Strict => 0|1 >> 581 582This is a placeholder option. 583 584=back 585 586=head2 Examples 587 588TODO 589 590=head1 Methods 591 592=head2 print 593 594Usage is 595 596 $z->print($data) 597 print $z $data 598 599Compresses and outputs the contents of the C<$data> parameter. This 600has the same behaviour as the C<print> built-in. 601 602Returns true if successful. 603 604=head2 printf 605 606Usage is 607 608 $z->printf($format, $data) 609 printf $z $format, $data 610 611Compresses and outputs the contents of the C<$data> parameter. 612 613Returns true if successful. 614 615=head2 syswrite 616 617Usage is 618 619 $z->syswrite $data 620 $z->syswrite $data, $length 621 $z->syswrite $data, $length, $offset 622 623Compresses and outputs the contents of the C<$data> parameter. 624 625Returns the number of uncompressed bytes written, or C<undef> if 626unsuccessful. 627 628=head2 write 629 630Usage is 631 632 $z->write $data 633 $z->write $data, $length 634 $z->write $data, $length, $offset 635 636Compresses and outputs the contents of the C<$data> parameter. 637 638Returns the number of uncompressed bytes written, or C<undef> if 639unsuccessful. 640 641=head2 flush 642 643Usage is 644 645 $z->flush; 646 $z->flush($flush_type); 647 648Flushes any pending compressed data to the output file/buffer. 649 650This method takes an optional parameter, C<$flush_type>, that controls 651how the flushing will be carried out. By default the C<$flush_type> 652used is C<Z_FINISH>. Other valid values for C<$flush_type> are 653C<Z_NO_FLUSH>, C<Z_SYNC_FLUSH>, C<Z_FULL_FLUSH> and C<Z_BLOCK>. It is 654strongly recommended that you only set the C<flush_type> parameter if 655you fully understand the implications of what it does - overuse of C<flush> 656can seriously degrade the level of compression achieved. See the C<zlib> 657documentation for details. 658 659Returns true on success. 660 661=head2 tell 662 663Usage is 664 665 $z->tell() 666 tell $z 667 668Returns the uncompressed file offset. 669 670=head2 eof 671 672Usage is 673 674 $z->eof(); 675 eof($z); 676 677Returns true if the C<close> method has been called. 678 679=head2 seek 680 681 $z->seek($position, $whence); 682 seek($z, $position, $whence); 683 684Provides a sub-set of the C<seek> functionality, with the restriction 685that it is only legal to seek forward in the output file/buffer. 686It is a fatal error to attempt to seek backward. 687 688Empty parts of the file/buffer will have NULL (0x00) bytes written to them. 689 690The C<$whence> parameter takes one the usual values, namely SEEK_SET, 691SEEK_CUR or SEEK_END. 692 693Returns 1 on success, 0 on failure. 694 695=head2 binmode 696 697Usage is 698 699 $z->binmode 700 binmode $z ; 701 702This is a noop provided for completeness. 703 704=head2 opened 705 706 $z->opened() 707 708Returns true if the object currently refers to a opened file/buffer. 709 710=head2 autoflush 711 712 my $prev = $z->autoflush() 713 my $prev = $z->autoflush(EXPR) 714 715If the C<$z> object is associated with a file or a filehandle, this method 716returns the current autoflush setting for the underlying filehandle. If 717C<EXPR> is present, and is non-zero, it will enable flushing after every 718write/print operation. 719 720If C<$z> is associated with a buffer, this method has no effect and always 721returns C<undef>. 722 723B<Note> that the special variable C<$|> B<cannot> be used to set or 724retrieve the autoflush setting. 725 726=head2 input_line_number 727 728 $z->input_line_number() 729 $z->input_line_number(EXPR) 730 731This method always returns C<undef> when compressing. 732 733=head2 fileno 734 735 $z->fileno() 736 fileno($z) 737 738If the C<$z> object is associated with a file or a filehandle, C<fileno> 739will return the underlying file descriptor. Once the C<close> method is 740called C<fileno> will return C<undef>. 741 742If the C<$z> object is associated with a buffer, this method will return 743C<undef>. 744 745=head2 close 746 747 $z->close() ; 748 close $z ; 749 750Flushes any pending compressed data and then closes the output file/buffer. 751 752For most versions of Perl this method will be automatically invoked if 753the IO::Compress::Deflate object is destroyed (either explicitly or by the 754variable with the reference to the object going out of scope). The 755exceptions are Perl versions 5.005 through 5.00504 and 5.8.0. In 756these cases, the C<close> method will be called automatically, but 757not until global destruction of all live objects when the program is 758terminating. 759 760Therefore, if you want your scripts to be able to run on all versions 761of Perl, you should call C<close> explicitly and not rely on automatic 762closing. 763 764Returns true on success, otherwise 0. 765 766If the C<AutoClose> option has been enabled when the IO::Compress::Deflate 767object was created, and the object is associated with a file, the 768underlying file will also be closed. 769 770=head2 newStream([OPTS]) 771 772Usage is 773 774 $z->newStream( [OPTS] ) 775 776Closes the current compressed data stream and starts a new one. 777 778OPTS consists of any of the options that are available when creating 779the C<$z> object. 780 781See the L</"Constructor Options"> section for more details. 782 783=head2 deflateParams 784 785Usage is 786 787 $z->deflateParams 788 789TODO 790 791=head1 Importing 792 793A number of symbolic constants are required by some methods in 794C<IO::Compress::Deflate>. None are imported by default. 795 796=over 5 797 798=item :all 799 800Imports C<deflate>, C<$DeflateError> and all symbolic 801constants that can be used by C<IO::Compress::Deflate>. Same as doing this 802 803 use IO::Compress::Deflate qw(deflate $DeflateError :constants) ; 804 805=item :constants 806 807Import all symbolic constants. Same as doing this 808 809 use IO::Compress::Deflate qw(:flush :level :strategy) ; 810 811=item :flush 812 813These symbolic constants are used by the C<flush> method. 814 815 Z_NO_FLUSH 816 Z_PARTIAL_FLUSH 817 Z_SYNC_FLUSH 818 Z_FULL_FLUSH 819 Z_FINISH 820 Z_BLOCK 821 822=item :level 823 824These symbolic constants are used by the C<Level> option in the constructor. 825 826 Z_NO_COMPRESSION 827 Z_BEST_SPEED 828 Z_BEST_COMPRESSION 829 Z_DEFAULT_COMPRESSION 830 831=item :strategy 832 833These symbolic constants are used by the C<Strategy> option in the constructor. 834 835 Z_FILTERED 836 Z_HUFFMAN_ONLY 837 Z_RLE 838 Z_FIXED 839 Z_DEFAULT_STRATEGY 840 841=back 842 843=head1 EXAMPLES 844 845=head2 Apache::GZip Revisited 846 847See L<IO::Compress::FAQ|IO::Compress::FAQ/"Apache::GZip Revisited"> 848 849=head2 Working with Net::FTP 850 851See L<IO::Compress::FAQ|IO::Compress::FAQ/"Compressed files and Net::FTP"> 852 853=head1 SUPPORT 854 855General feedback/questions/bug reports should be sent to 856L<https://github.com/pmqs/IO-Compress/issues> (preferred) or 857L<https://rt.cpan.org/Public/Dist/Display.html?Name=IO-Compress>. 858 859=head1 SEE ALSO 860 861L<Compress::Zlib>, L<IO::Compress::Gzip>, L<IO::Uncompress::Gunzip>, L<IO::Uncompress::Inflate>, L<IO::Compress::RawDeflate>, L<IO::Uncompress::RawInflate>, L<IO::Compress::Bzip2>, L<IO::Uncompress::Bunzip2>, L<IO::Compress::Lzma>, L<IO::Uncompress::UnLzma>, L<IO::Compress::Xz>, L<IO::Uncompress::UnXz>, L<IO::Compress::Lzip>, L<IO::Uncompress::UnLzip>, L<IO::Compress::Lzop>, L<IO::Uncompress::UnLzop>, L<IO::Compress::Lzf>, L<IO::Uncompress::UnLzf>, L<IO::Compress::Zstd>, L<IO::Uncompress::UnZstd>, L<IO::Uncompress::AnyInflate>, L<IO::Uncompress::AnyUncompress> 862 863L<IO::Compress::FAQ|IO::Compress::FAQ> 864 865L<File::GlobMapper|File::GlobMapper>, L<Archive::Zip|Archive::Zip>, 866L<Archive::Tar|Archive::Tar>, 867L<IO::Zlib|IO::Zlib> 868 869For RFC 1950, 1951 and 1952 see 870L<https://datatracker.ietf.org/doc/html/rfc1950>, 871L<https://datatracker.ietf.org/doc/html/rfc1951> and 872L<https://datatracker.ietf.org/doc/html/rfc1952> 873 874The I<zlib> compression library was written by Jean-loup Gailly 875C<gzip@prep.ai.mit.edu> and Mark Adler C<madler@alumni.caltech.edu>. 876 877The primary site for the I<zlib> compression library is 878L<http://www.zlib.org>. 879 880The primary site for the I<zlib-ng> compression library is 881L<https://github.com/zlib-ng/zlib-ng>. 882 883The primary site for gzip is L<http://www.gzip.org>. 884 885=head1 AUTHOR 886 887This module was written by Paul Marquess, C<pmqs@cpan.org>. 888 889=head1 MODIFICATION HISTORY 890 891See the Changes file. 892 893=head1 COPYRIGHT AND LICENSE 894 895Copyright (c) 2005-2023 Paul Marquess. All rights reserved. 896 897This program is free software; you can redistribute it and/or 898modify it under the same terms as Perl itself. 899