In perl.git, the branch maint-5.10 has been updated <http://perl5.git.perl.org/perl.git/commitdiff/a63f74de9db48e64aeb3de62157d0702d2cbd7a1?hp=ab037dfb70229fb7260174dece1e9c4e98e862eb>
- Log ----------------------------------------------------------------- commit a63f74de9db48e64aeb3de62157d0702d2cbd7a1 Author: David Mitchell <[email protected]> Date: Sat Jul 25 11:54:16 2009 +0100 add -b option to makerel to make a .bz2 file (cherry picked from commit 85bdf03b25729816eedfea55a7f2c32c4bb80fba) M Porting/makerel M Porting/release_managers_guide.pod commit 712c2294eb7e7187b48954f43bb455f5b8272437 Author: David Mitchell <[email protected]> Date: Sat Jul 25 11:38:30 2009 +0100 autodie 2.06_01 (cherry picked from commit 7840a289bfa1b7a230055bb32f02d6873672b75b) M Porting/Maintainers.pl M lib/Fatal.pm M lib/autodie.pm M lib/autodie/exception.pm M lib/autodie/exception/system.pm M lib/autodie/hints.pm ----------------------------------------------------------------------- Summary of changes: Porting/Maintainers.pl | 2 +- Porting/makerel | 19 +++++++++++++------ Porting/release_managers_guide.pod | 17 +++++++++-------- lib/Fatal.pm | 4 +++- lib/autodie.pm | 2 +- lib/autodie/exception.pm | 15 ++++++++++++++- lib/autodie/exception/system.pm | 2 +- lib/autodie/hints.pm | 2 +- 8 files changed, 43 insertions(+), 20 deletions(-) diff --git a/Porting/Maintainers.pl b/Porting/Maintainers.pl index 7b2e5dc..d7ab22e 100755 --- a/Porting/Maintainers.pl +++ b/Porting/Maintainers.pl @@ -205,7 +205,7 @@ package Maintainers; 'autodie' => { 'MAINTAINER' => 'pjf', - 'DISTRIBUTION' => 'PJF/autodie-2.06.tar.gz', + 'DISTRIBUTION' => 'PJF/autodie-2.06_01.tar.gz', 'FILES' => q[lib/Fatal.pm lib/autodie.pm lib/autodie], 'EXCLUDED' => [ qr{^inc/Module/}, diff --git a/Porting/makerel b/Porting/makerel index b126164..8c9e9c1 100644 --- a/Porting/makerel +++ b/Porting/makerel @@ -16,16 +16,17 @@ use Getopt::Std; $|=1; sub usage { die <<EOF; } -usage: $0 [ -r rootdir ] [-s suffix ] +usage: $0 [ -r rootdir ] [-s suffix ] [ -b ] -r rootdir directory under which to create the build dir and tarball defaults to '..' -s suffix suffix to append to to the perl-x.y.z dir and tarball name defaults to the concatenaion of the local_patches entry in patchlevel.h (or blank, if none) + -b make a .bz2 file in addtion to a .gz file EOF my %opts; -getopts('r:s:', \%opts) or usage; +getopts('br:s:', \%opts) or usage; @ARGV && usage; $relroot = defined $opts{r} ? $opts{r} : ".."; @@ -186,11 +187,17 @@ print "\n"; chdir ".." or die $!; -print "Creating and compressing the tar file...\n"; my $src = (-e $perl) ? $perl : 'perl'; # 'perl' in maint branch + +print "Creating and compressing the tar.gz file...\n"; $cmd = "tar cf - $reldir | gzip --best > $reldir.tar.gz"; -system($cmd) == 0 - or die "$cmd failed"; -print "\n"; +system($cmd) == 0 or die "$cmd failed"; +if ($opts{b}) { + print "Creating and compressing the tar.bz2 file...\n"; + $cmd = "tar cf - $reldir | bzip2 > $reldir.tar.bz2"; + system($cmd) == 0 or die "$cmd failed"; +} + +print "\n"; system("ls -ld $perl*"); diff --git a/Porting/release_managers_guide.pod b/Porting/release_managers_guide.pod index daf62e0..1c11a87 100644 --- a/Porting/release_managers_guide.pod +++ b/Porting/release_managers_guide.pod @@ -102,26 +102,27 @@ the tarball and directory name: $ cd root/of/perl/tree $ git clean -xdf # make sure perl and git agree on files - $ perl Porting/makerel -s `git describe` # for a snapshot - $ perl Porting/makerel -s RC1 # for a release candidate - $ perl Porting/makerel # for a final release + $ perl Porting/makerel -b -s `git describe` # for a snapshot + $ perl Porting/makerel -b -s RC1 # for a release candidate + $ perl Porting/makerel -b # for a final release This creates the directory F<../perl-x.y.z-RC1> or similar, copies all the MANIFEST files into it, sets the correct permissions on them, adds DOS line endings to some, then tars it up as -F<../perl-x.y.z-RC1.tar.gz>. +F<../perl-x.y.z-RC1.tar.gz>. With C<-b>, it also creates a C<tar.bz2> file. XXX if we go for extra tags and branches stuff, then add the extra details here =item * -Copy the tarball to a web server somewhere you have access to. +Copy the tarballs (.gz and possibly .bz2) to a web server somewhere you +have access to. =item * -Download the tarball to some other machine (for a release candidate, to two or -more servers: IRC is good for this). +Download the tarball to some other machine (for a release candidate, to +two or more servers: IRC is good for this). =item * @@ -157,7 +158,7 @@ Install an XS module. =item * -If all is well, announce the snaphot to p5p. (For a release candidate, +If all is well, announce the snapshot to p5p. (For a release candidate, instead follow the further steps described later.) =back diff --git a/lib/Fatal.pm b/lib/Fatal.pm index e756957..18e71ed 100644 --- a/lib/Fatal.pm +++ b/lib/Fatal.pm @@ -39,7 +39,7 @@ use constant ERROR_58_HINTS => q{Non-subroutine %s hints for %s are not supporte use constant MIN_IPC_SYS_SIMPLE_VER => 0.12; # All the Fatal/autodie modules share the same version number. -our $VERSION = '2.06'; +our $VERSION = '2.06_01'; our $Debug ||= 0; @@ -101,6 +101,7 @@ my %TAGS = ( ':2.04' => [qw(:default)], ':2.05' => [qw(:default)], ':2.06' => [qw(:default)], + ':2.06_01' => [qw(:default)], ); $TAGS{':all'} = [ keys %TAGS ]; @@ -698,6 +699,7 @@ sub _one_invocation { function => q{$human_sub_name}, args => [ @argv ], pragma => q{$class}, errno => \$!, context => \$context, return => \$retval, + eval_error => \$@ ) }; diff --git a/lib/autodie.pm b/lib/autodie.pm index efb93d3..8e8e709 100644 --- a/lib/autodie.pm +++ b/lib/autodie.pm @@ -8,7 +8,7 @@ our @ISA = qw(Fatal); our $VERSION; BEGIN { - $VERSION = '2.06'; + $VERSION = '2.06_01'; } use constant ERROR_WRONG_FATAL => q{ diff --git a/lib/autodie/exception.pm b/lib/autodie/exception.pm index ac578a1..8646099 100644 --- a/lib/autodie/exception.pm +++ b/lib/autodie/exception.pm @@ -14,7 +14,7 @@ use overload use if ($] >= 5.010), overload => '~~' => "matches"; -our $VERSION = '2.06'; +our $VERSION = '2.06_01'; my $PACKAGE = __PACKAGE__; # Useful to have a scalar for hash keys. @@ -170,6 +170,18 @@ set on failure. sub errno { return $_[0]->{$PACKAGE}{errno}; } +=head3 eval_error + + my $old_eval_error = $E->eval_error; + +The contents of C<$@> immediately after autodie triggered an +exception. This may be useful when dealing with modules such +as L<Text::Balanced> that set (but do not throw) C<$@> on error. + +=cut + +sub eval_error { return $_[0]->{$PACKAGE}{eval_error}; } + =head3 matches if ( $e->matches('open') ) { ... } @@ -698,6 +710,7 @@ sub _init { $this->{$PACKAGE}{context} = $args{context}; $this->{$PACKAGE}{return} = $args{return}; + $this->{$PACKAGE}{eval_error} = $args{eval_error}; $this->{$PACKAGE}{args} = $args{args} || []; $this->{$PACKAGE}{function}= $args{function} or diff --git a/lib/autodie/exception/system.pm b/lib/autodie/exception/system.pm index ebfa6ba..07cd1c9 100644 --- a/lib/autodie/exception/system.pm +++ b/lib/autodie/exception/system.pm @@ -5,7 +5,7 @@ use warnings; use base 'autodie::exception'; use Carp qw(croak); -our $VERSION = '2.06'; +our $VERSION = '2.06_01'; my $PACKAGE = __PACKAGE__; diff --git a/lib/autodie/hints.pm b/lib/autodie/hints.pm index f5ba5d8..e7be03a 100644 --- a/lib/autodie/hints.pm +++ b/lib/autodie/hints.pm @@ -5,7 +5,7 @@ use warnings; use constant PERL58 => ( $] < 5.009 ); -our $VERSION = '2.06'; +our $VERSION = '2.06_01'; =head1 NAME -- Perl5 Master Repository
