Skip to content

Commit

Permalink
lib/Module/Build/Base.pm - tidying in make_tarball
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.perl.org/modules/Module-Build/trunk@12147 50811bd7-b8ce-0310-adc1-d9db26280581
  • Loading branch information
ewilhelm committed Dec 11, 2008
1 parent 7e11387 commit b2cc12f
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions lib/Module/Build/Base.pm
Expand Up @@ -3784,16 +3784,18 @@ sub make_tarball {
$self->do_system($self->split_like_shell($self->{args}{gzip}), "$file.tar") if $self->{args}{gzip};
} else {
require Archive::Tar;

# Archive::Tar versions >= 1.09 use the following to enable a compatibility
# hack so that the resulting archive is compatible with older clients.
$Archive::Tar::DO_NOT_USE_PREFIX = 0;

my $files = $self->rscan_dir($dir);
my $tar = Archive::Tar->new;
$tar->add_files( @$files );
for my $f ( $tar->get_files ) {
$f->mode( $f->mode & ~022 ); # chmod go-w
my $tar = Archive::Tar->new;
$tar->add_files(@$files);
for my $f ($tar->get_files) {
$f->mode($f->mode & ~022); # chmod go-w
}
$tar->write( "$file.tar.gz", 1 );
$tar->write("$file.tar.gz", 1);
}
}

Expand Down

0 comments on commit b2cc12f

Please sign in to comment.