rpms/perl/F-12 perl-update-Archive-Tar.patch, 1.1, 1.2 perl.spec, 1.239, 1.240

Petr Pisar ppisar at fedoraproject.org
Thu Jul 8 08:48:19 UTC 2010


Author: ppisar

Update of /cvs/pkgs/rpms/perl/F-12
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv30644

Modified Files:
	perl-update-Archive-Tar.patch perl.spec 
Log Message:
Upgrade Archive::Tar to 1.62

perl-update-Archive-Tar.patch:
 MANIFEST                                                       |    9 
 lib/Archive/Tar.pm                                             |  683 +++++++---
 lib/Archive/Tar/Constant.pm                                    |   38 
 lib/Archive/Tar/File.pm                                        |  104 +
 lib/Archive/Tar/bin/ptar                                       |  105 -
 lib/Archive/Tar/t/02_methods.t                                 |  372 ++---
 lib/Archive/Tar/t/04_resolved_issues.t                         |   48 
 lib/Archive/Tar/t/05_iter.t                                    |   65 
 lib/Archive/Tar/t/06_error.t                                   |   39 
 lib/Archive/Tar/t/90_symlink.t                                 |   62 
 lib/Archive/Tar/t/99_pod.t                                     |   24 
 lib/Archive/Tar/t/src/header/signed.tar.packed                 |  243 +++
 lib/Archive/Tar/t/src/linktest/linktest_missing_dir.tar.packed |  243 +++
 lib/Archive/Tar/t/src/linktest/linktest_with_dir.tar.packed    |  232 +++
 lib/Archive/Tar/t/src/long/foo.tbz.packed                      |   23 
 lib/Archive/Tar/t/src/short/foo.tbz.packed                     |   19 
 16 files changed, 1840 insertions(+), 469 deletions(-)

View full diff with command:
/usr/bin/cvs -n -f diff -kk -u -p -N -r 1.1 -r 1.2 perl-update-Archive-Tar.patchIndex: perl-update-Archive-Tar.patch
===================================================================
RCS file: /cvs/pkgs/rpms/perl/F-12/perl-update-Archive-Tar.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- perl-update-Archive-Tar.patch	11 Mar 2009 21:12:37 -0000	1.1
+++ perl-update-Archive-Tar.patch	8 Jul 2010 08:48:19 -0000	1.2
@@ -1,31 +1,157 @@
-Archive-Tar-1.46
-
-diff -urN perl-5.10.0.orig/MANIFEST perl-5.10.0/MANIFEST
---- perl-5.10.0.orig/MANIFEST	2009-02-20 18:22:32.000000000 +0100
-+++ perl-5.10.0/MANIFEST	2009-03-11 17:11:27.000000000 +0100
-@@ -1413,12 +1413,19 @@
- lib/Archive/Tar/t/02_methods.t	Archive::Tar tests
- lib/Archive/Tar/t/03_file.t	Archive::Tar tests
- lib/Archive/Tar/t/04_resolved_issues.t	Archive::Tar tests
-+lib/Archive/Tar/t/05_iter.t	Archive::Tar tests
-+lib/Archive/Tar/t/90_symlink.t	Archive::Tar tests
-+lib/Archive/Tar/t/src/linktest/linktest_missing_dir.tar.packed	Archive::Tar tests
-+lib/Archive/Tar/t/src/linktest/linktest_with_dir.tar.packed	Archive::Tar tests
- lib/Archive/Tar/t/src/long/b	Archive::Tar tests
- lib/Archive/Tar/t/src/long/bar.tar.packed	Archive::Tar tests
-+lib/Archive/Tar/t/src/long/foo.tbz.packed	Archive::Tar tests
- lib/Archive/Tar/t/src/long/foo.tgz.packed	Archive::Tar tests
- lib/Archive/Tar/t/src/short/b	Archive::Tar tests
- lib/Archive/Tar/t/src/short/bar.tar.packed	Archive::Tar tests
-+lib/Archive/Tar/t/src/short/foo.tbz.packed	Archive::Tar tests
- lib/Archive/Tar/t/src/short/foo.tgz.packed	Archive::Tar tests
-+lib/Archive/Tar/t/src/header/signed.tar.packed	Archive::Tar tests
- lib/assert.pl			assertion and panic with stack trace
- lib/Attribute/Handlers/Changes	Attribute::Handlers
- lib/Attribute/Handlers/demo/demo2.pl	Attribute::Handlers demo
-diff -urN perl-5.10.0.orig/lib/Archive/Tar/Constant.pm perl-5.10.0/lib/Archive/Tar/Constant.pm
---- perl-5.10.0.orig/lib/Archive/Tar/Constant.pm	2009-02-20 11:21:14.000000000 +0100
-+++ perl-5.10.0/lib/Archive/Tar/Constant.pm	2009-03-11 17:11:27.000000000 +0100
+Archive-Tar-1.62
+diff -Naur perl-5.10.0.orig/lib/Archive/Tar/bin/ptar perl-5.10.0/lib/Archive/Tar/bin/ptar
+--- perl-5.10.0.orig/lib/Archive/Tar/bin/ptar	2007-12-18 11:47:07.000000000 +0100
++++ perl-5.10.0/lib/Archive/Tar/bin/ptar	2010-07-07 17:49:03.341094154 +0200
+@@ -1,12 +1,13 @@
+ #!/usr/bin/perl
+ use strict;
+ 
++use File::Find;
+ use Getopt::Std;
+ use Archive::Tar;
+-use File::Find;
++use Data::Dumper;
+ 
+ my $opts = {};
+-getopts('dcvzthxf:I', $opts) or die usage();
++getopts('Ddcvzthxf:I', $opts) or die usage();
+ 
+ ### show the help message ###
+ die usage() if $opts->{h};
+@@ -33,72 +34,63 @@
+     find( sub { push @files, $File::Find::name;
+                 print $File::Find::name.$/ if $verbose }, @ARGV );
+ 
+-    Archive::Tar->create_archive( $file, $compress, @files );
+-    exit;
+-}
+-
+-my $tar = Archive::Tar->new($file, $compress);
++    if ($file eq '-') {
++        use IO::Handle;
++        $file = IO::Handle->new();
++        $file->fdopen(fileno(STDOUT),"w");
++    }
+ 
+-if( $opts->{t} ) {
+-    print map { $_->full_path . $/ } $tar->get_files;
++    Archive::Tar->create_archive( $file, $compress, @files );
+ 
+-} elsif( $opts->{x} ) {
+-    print map { $_->full_path . $/ } $tar->get_files
+-        if $verbose;
+-    Archive::Tar->extract_archive($file, $compress);
++} else {
++    if ($file eq '-') {
++        use IO::Handle;
++        $file = IO::Handle->new();
++        $file->fdopen(fileno(STDIN),"r");
++    }
++
++    ### print the files we're finding?
++    my $print = $verbose || $opts->{'t'} || 0;
++
++    my $iter = Archive::Tar->iter( $file );
++        
++    while( my $f = $iter->() ) {
++        print $f->full_path . $/ if $print;
++
++        ### data dumper output
++        print Dumper( $f ) if $opts->{'D'};
++        
++        ### extract it
++        $f->extract if $opts->{'x'};
++    }
+ }
+ 
+-
+-
++### pod & usage in one
+ sub usage {
+-    qq[
+-Usage:  ptar -c [-v] [-z] [-f ARCHIVE_FILE] FILE FILE ...
+-        ptar -x [-v] [-z] [-f ARCHIVE_FILE]
+-        ptar -t [-z] [-f ARCHIVE_FILE]
+-        ptar -h
+-
+-    ptar is a small, tar look-alike program that uses the perl module
+-    Archive::Tar to extract, create and list tar archives.
+-
+-Options:
+-    x   Extract from ARCHIVE_FILE
+-    c   Create ARCHIVE_FILE from FILE
+-    t   List the contents of ARCHIVE_FILE
+-    f   Name of the ARCHIVE_FILE to use. Default is './default.tar'
+-    z   Read/Write zlib compressed ARCHIVE_FILE (not always available)
+-    v   Print filenames as they are added or extraced from ARCHIVE_FILE
+-    h   Prints this help message
+-    I   Enable 'Insecure Extract Mode', which allows archives to extract
+-        files outside the current working directory. (Not advised).
+-
+-See Also:
+-    tar(1)
+-    Archive::Tar
+-
+-    \n]
+-}
++    my $usage .= << '=cut';
++=pod
+ 
+ =head1 NAME
+ 
+-ptar - a tar-like program written in perl
++    ptar - a tar-like program written in perl
+ 
+ =head1 DESCRIPTION
+ 
+-ptar is a small, tar look-alike program that uses the perl module
+-Archive::Tar to extract, create and list tar archives.
++    ptar is a small, tar look-alike program that uses the perl module
++    Archive::Tar to extract, create and list tar archives.
+ 
+ =head1 SYNOPSIS
+ 
+-    ptar -c [-v] [-z] [-f ARCHIVE_FILE] FILE FILE ...
+-    ptar -x [-v] [-z] [-f ARCHIVE_FILE]
+-    ptar -t [-z] [-f ARCHIVE_FILE]
++    ptar -c [-v] [-z] [-f ARCHIVE_FILE | -] FILE FILE ...
++    ptar -x [-v] [-z] [-f ARCHIVE_FILE | -]
++    ptar -t [-z] [-f ARCHIVE_FILE | -]
+     ptar -h
+ 
+ =head1 OPTIONS
+ 
+-    x   Extract from ARCHIVE_FILE
+-    c   Create ARCHIVE_FILE from FILE
+-    t   List the contents of ARCHIVE_FILE
++    c   Create ARCHIVE_FILE or STDOUT (-) from FILE
++    x   Extract from ARCHIVE_FILE or STDIN (-)
++    t   List the contents of ARCHIVE_FILE or STDIN (-)
+     f   Name of the ARCHIVE_FILE to use. Default is './default.tar'
+     z   Read/Write zlib compressed ARCHIVE_FILE (not always available)
+     v   Print filenames as they are added or extraced from ARCHIVE_FILE
+@@ -106,6 +98,17 @@
+ 
+ =head1 SEE ALSO
+ 
+-tar(1), L<Archive::Tar>.
++    tar(1), L<Archive::Tar>.
+ 
+ =cut
++
++    ### strip the pod directives
++    $usage =~ s/=pod\n//g;
++    $usage =~ s/=head1 //g;
++    
++    ### add some newlines
++    $usage .= $/.$/;
++    
++    return $usage;
++}
++
+diff -Naur perl-5.10.0.orig/lib/Archive/Tar/Constant.pm perl-5.10.0/lib/Archive/Tar/Constant.pm
+--- perl-5.10.0.orig/lib/Archive/Tar/Constant.pm	2007-12-18 11:47:07.000000000 +0100
++++ perl-5.10.0/lib/Archive/Tar/Constant.pm	2010-07-07 17:52:23.535086145 +0200
 @@ -2,20 +2,16 @@
  
  BEGIN {
@@ -41,7 +167,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
 -                LABEL NAME_LENGTH STRIP_MODE ON_VMS
 -            ];
 +    
-+    $VERSION    = '0.02';
++    $VERSION    = '1.62';
[...3714 lines suppressed...]
@@ -3035,8 +3229,19 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  
  sub no_string_support {
      croak("You have to install IO::String to support writing archives to strings");
-@@ -1542,13 +1756,13 @@
+@@ -1540,15 +1779,24 @@
+ 
+ The default is C<1>.
  
++=head2 $Archive::Tar::SAME_PERMISSIONS
++
++When, C<$Archive::Tar::CHMOD> is enabled, this setting controls whether
++the permissions on files from the archive are used without modification
++of if they are filtered by removing any setid bits and applying the
++current umask.
++
++The default is C<1> for the root user and C<0> for normal users.
++
  =head2 $Archive::Tar::DO_NOT_USE_PREFIX
  
 -By default, C<Archive::Tar> will try to put paths that are over 
@@ -3055,7 +3260,19 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  C<GNU Extended Header> feature.
  
  Note that clients who do not support the C<GNU Extended Header>
-@@ -1589,11 +1803,11 @@
+@@ -1582,6 +1830,11 @@
+ 
+     warn $tar->error unless $tar->extract;
+ 
++Note that in older versions of this module, the C<error()> method
++would return an effectively global value even when called an instance
++method as above. This has since been fixed, and multiple instances of
++C<Archive::Tar> now have separate error strings.
++
+ =head2 $Archive::Tar::INSECURE_EXTRACT_MODE
+ 
+ This variable indicates whether C<Archive::Tar> should allow
+@@ -1589,11 +1842,11 @@
  
  Allowing this could have security implications, as a malicious
  tar archive could alter or replace any file the extracting user
@@ -3071,7 +3288,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  set this variable to C<true>.
  
  Note that this is a backwards incompatible change from version
-@@ -1601,9 +1815,9 @@
+@@ -1601,9 +1854,9 @@
  
  =head2 $Archive::Tar::HAS_PERLIO
  
@@ -3083,7 +3300,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  
  If you feel strongly about disabling it, set this variable to
  C<false>. Note that you will then need C<IO::String> installed
-@@ -1614,7 +1828,7 @@
+@@ -1614,7 +1867,7 @@
  
  =head2 $Archive::Tar::HAS_IO_STRING
  
@@ -3092,7 +3309,21 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  C<IO::String> support loaded. This will be enabled for any perl
  that has a loadable C<IO::String> module.
  
-@@ -1645,18 +1859,24 @@
+@@ -1625,6 +1878,13 @@
+ Don't change this variable unless you B<really> know what you're
+ doing.
+ 
++=head2 $Archive::Tar::ZERO_PAD_NUMBERS
++
++This variable holds a boolean indicating if we will create
++zero padded numbers for C<size>, C<mtime> and C<checksum>. 
++The default is C<0>, indicating that we will create space padded
++numbers. Added for compatibility with C<busybox> implementations.
++
+ =head1 FAQ
+ 
+ =over 4
+@@ -1645,18 +1905,24 @@
  C<IO::Zlib> doesn't support C<seek> on their filehandles, there is little
  choice but to read the archive into memory.
  This is ok if you want to do in-memory manipulation of the archive.
@@ -3120,7 +3351,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  
  =item What do you do with unsupported filetypes in an archive?
  
-@@ -1666,8 +1886,9 @@
+@@ -1666,8 +1932,9 @@
  
  This does require you to read the entire archive in to memory first,
  since otherwise we wouldn't know what data to fill the copy with.
@@ -3132,7 +3363,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  
  For other filetypes, like C<chardevs> and C<blockdevs> we'll warn that
  the extraction of this particular item didn't work.
-@@ -1680,7 +1901,7 @@
+@@ -1680,7 +1947,7 @@
  C<POSIX header prefix>. Non-POSIX-compatible clients may not support
  this part of the specification, and may only support the C<GNU Extended
  Header> functionality. To facilitate those clients, you can set the
@@ -3141,7 +3372,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  C<GLOBAL VARIABLES> section for details on this variable.
  
  Note that GNU tar earlier than version 1.14 does not cope well with
-@@ -1696,9 +1917,9 @@
+@@ -1696,9 +1963,9 @@
  based on your criteria. For example, to extract only files that have
  the string C<foo> in their title, you would use:
  
@@ -3153,7 +3384,7 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  
  This way, you can filter on any attribute of the files in the archive.
  Consult the C<Archive::Tar::File> documentation on how to use these
-@@ -1775,22 +1996,22 @@
+@@ -1775,27 +2042,51 @@
  
      $tar->add_data('file.txt', $data);
  
@@ -3180,19 +3411,48 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  because a tarball can contain many files, and each of which could be
  encoded in a different way.
  
-@@ -1852,15 +2073,15 @@
+ =back
+ 
++=head1 CAVEATS
++
++The AIX tar does not fill all unused space in the tar archive with 0x00. 
++This sometimes leads to warning messages from C<Archive::Tar>.
++
++  Invalid header block at offset nnn
++
++A fix for that problem is scheduled to be released in the following levels
++of AIX, all of which should be coming out in the 4th quarter of 2009:
++
++ AIX 5.3 TL7 SP10
++ AIX 5.3 TL8 SP8
++ AIX 5.3 TL9 SP5
++ AIX 5.3 TL10 SP2
++ 
++ AIX 6.1 TL0 SP11
++ AIX 6.1 TL1 SP7
++ AIX 6.1 TL2 SP6
++ AIX 6.1 TL3 SP3
++
++The IBM APAR number for this problem is IZ50240 (Reported component ID: 
++5765G0300 / AIX 5.3). It is possible to get an ifix for that problem. 
++If you need an ifix please contact your local IBM AIX support.
++
+ =head1 TODO
+ 
+ =over 4
+@@ -1852,15 +2143,15 @@
  
  =head1 ACKNOWLEDGEMENTS
  
 -Thanks to Sean Burke, Chris Nandor, Chip Salzenberg, Tim Heaney and
 -especially Andrew Savige for their help and suggestions.
-+Thanks to Sean Burke, Chris Nandor, Chip Salzenberg, Tim Heaney, Gisle Aas
-+and especially Andrew Savige for their help and suggestions.
++Thanks to Sean Burke, Chris Nandor, Chip Salzenberg, Tim Heaney, Gisle Aas,
++Rainer Tammer and especially Andrew Savige for their help and suggestions.
  
  =head1 COPYRIGHT
  
 -This module is copyright (c) 2002 - 2007 Jos Boumans 
-+This module is copyright (c) 2002 - 2008 Jos Boumans
++This module is copyright (c) 2002 - 2009 Jos Boumans
  E<lt>kane at cpan.orgE<gt>. All rights reserved.
  
 -This library is free software; you may redistribute and/or modify 
@@ -3200,3 +3460,27 @@ diff -urN perl-5.10.0.orig/lib/Archive/T
  it under the same terms as Perl itself.
  
  =cut
+diff -Naur perl-5.10.0.orig/MANIFEST perl-5.10.0/MANIFEST
+--- perl-5.10.0.orig/MANIFEST	2007-12-18 11:47:07.000000000 +0100
++++ perl-5.10.0/MANIFEST	2010-07-07 18:19:41.043086096 +0200
+@@ -1413,11 +1413,20 @@
+ lib/Archive/Tar/t/02_methods.t	Archive::Tar tests
+ lib/Archive/Tar/t/03_file.t	Archive::Tar tests
+ lib/Archive/Tar/t/04_resolved_issues.t	Archive::Tar tests
++lib/Archive/Tar/t/05_iter.t Archive::Tar tests
++lib/Archive/Tar/t/06_error.t Archive::Tar tests
++lib/Archive/Tar/t/90_symlink.t  Archive::Tar tests
++lib/Archive/Tar/t/99_pod.t  Archive::Tar tests
++lib/Archive/Tar/t/src/header/signed.tar.packed	Archive::Tar tests
++lib/Archive/Tar/t/src/linktest/linktest_missing_dir.tar.packed	Archive::Tar tests
++lib/Archive/Tar/t/src/linktest/linktest_with_dir.tar.packed	Archive::Tar tests
+ lib/Archive/Tar/t/src/long/b	Archive::Tar tests
+ lib/Archive/Tar/t/src/long/bar.tar.packed	Archive::Tar tests
++lib/Archive/Tar/t/src/long/foo.tbz.packed	Archive::Tar tests
+ lib/Archive/Tar/t/src/long/foo.tgz.packed	Archive::Tar tests
+ lib/Archive/Tar/t/src/short/b	Archive::Tar tests
+ lib/Archive/Tar/t/src/short/bar.tar.packed	Archive::Tar tests
++lib/Archive/Tar/t/src/short/foo.tbz.packed	Archive::Tar tests
+ lib/Archive/Tar/t/src/short/foo.tgz.packed	Archive::Tar tests
+ lib/assert.pl			assertion and panic with stack trace
+ lib/Attribute/Handlers/Changes	Attribute::Handlers


Index: perl.spec
===================================================================
RCS file: /cvs/pkgs/rpms/perl/F-12/perl.spec,v
retrieving revision 1.239
retrieving revision 1.240
diff -u -p -r1.239 -r1.240
--- perl.spec	7 Jul 2010 16:51:28 -0000	1.239
+++ perl.spec	8 Jul 2010 08:48:19 -0000	1.240
@@ -204,7 +204,7 @@ Patch100:	perl-update-constant.patch
 Patch101:	perl-update-Archive-Extract.patch
 %define			    Archive_Extract_version 0.30
 Patch102:	perl-update-Archive-Tar.patch
-%define			    Archive_Tar_version 1.46
+%define			    Archive_Tar_version 1.62
 Patch103:	perl-update-CGI.patch
 %define			    CGI_version 3.43
 Patch104:	perl-update-ExtUtils-CBuilder.patch
@@ -1956,6 +1956,8 @@ TMPDIR="$PWD/tmp" make test
 %changelog
 * Wed Jul  7 2010 Petr Pisar <ppisar at redhat.com> - 4:5.10.0-89
 - Fix perl-5.10.0-Encode-err.patch patch to be applicable
+- Fix incorrect return code on failed extraction by upgrading Archive::Tar to
+  1.62 (bug #607687)
 
 * Wed Mar 17 2010 Marcela Mašláňová <mmaslano at redhat.com> - 4:5.10.0-88
 - rebuild, e.g. Patch62 is missing in koji build



More information about the scm-commits mailing list