diff options
author | Jesse Vincent <jesse@bestpractical.com> | 2009-12-06 15:13:48 -0500 |
---|---|---|
committer | Jesse Vincent <jesse@bestpractical.com> | 2009-12-06 16:52:40 -0500 |
commit | 8b19c1f8f171b4db09e0f4369f5fa72b488e66bd (patch) | |
tree | fe9e9248aabfea166e8d9942a3ac2c815a9252c5 /cpan/ExtUtils-MakeMaker | |
parent | 7baa46900628573770d962400725b38c0773bf47 (diff) | |
download | perl-8b19c1f8f171b4db09e0f4369f5fa72b488e66bd.tar.gz |
Import ExtUtils::MakeMaker 6.55_03 from CPAN
Diffstat (limited to 'cpan/ExtUtils-MakeMaker')
35 files changed, 150 insertions, 92 deletions
diff --git a/cpan/ExtUtils-MakeMaker/Changes b/cpan/ExtUtils-MakeMaker/Changes index 2943c53417..2ea908319c 100644 --- a/cpan/ExtUtils-MakeMaker/Changes +++ b/cpan/ExtUtils-MakeMaker/Changes @@ -1,3 +1,10 @@ + Bug Fixes + * BUILD_REQUIRES will not be used when generating ppd, PRINT_PREREQ and + 'requires' section of META.yml (Alexandr Ciornii) + + OS/2 + * Better compatibility with miniperl [rt.cpan.org 48534] (Ilya Zakharevich) + 6.55_02 Wed Aug 5 00:36:36 PDT 2009 Feature Changes * PREFIX now applies to relative directories. This is a change since diff --git a/cpan/ExtUtils-MakeMaker/MANIFEST b/cpan/ExtUtils-MakeMaker/MANIFEST index 4f19e4ab57..b242cc55f6 100644 --- a/cpan/ExtUtils-MakeMaker/MANIFEST +++ b/cpan/ExtUtils-MakeMaker/MANIFEST @@ -1,5 +1,12 @@ +.gitignore bin/instmodsh Changes +inc/ExtUtils/Command.pm +inc/ExtUtils/Install.pm +inc/ExtUtils/Installed.pm +inc/ExtUtils/Manifest.pm +inc/ExtUtils/MANIFEST.SKIP +inc/ExtUtils/Packlist.pm lib/ExtUtils/Command/MM.pm lib/ExtUtils/Liblist.pm lib/ExtUtils/Liblist/Kid.pm @@ -30,6 +37,7 @@ lib/ExtUtils/MY.pm lib/ExtUtils/testlib.pm Makefile.PL MANIFEST This list of files +MANIFEST.SKIP NOTES PATCHING README @@ -58,6 +66,11 @@ t/lib/MakeMaker/Test/Setup/Problem.pm t/lib/MakeMaker/Test/Setup/Recurs.pm t/lib/MakeMaker/Test/Setup/XS.pm t/lib/MakeMaker/Test/Utils.pm +t/lib/Test/Builder.pm +t/lib/Test/Builder/IO/Scalar.pm +t/lib/Test/Builder/Module.pm +t/lib/Test/More.pm +t/lib/Test/Simple.pm t/lib/TieIn.pm t/lib/TieOut.pm t/Liblist.t @@ -101,3 +114,4 @@ t/WriteEmptyMakefile.t t/writemakefile_args.t t/xs.t TODO +META.yml Module meta-data (added by MakeMaker) diff --git a/cpan/ExtUtils-MakeMaker/bin/instmodsh b/cpan/ExtUtils-MakeMaker/bin/instmodsh index 5874aa61c7..5874aa61c7 100644..100755 --- a/cpan/ExtUtils-MakeMaker/bin/instmodsh +++ b/cpan/ExtUtils-MakeMaker/bin/instmodsh diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Command/MM.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Command/MM.pm index d4a0ef7d06..dc78117f12 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Command/MM.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Command/MM.pm @@ -10,7 +10,7 @@ our @ISA = qw(Exporter); our @EXPORT = qw(test_harness pod2man perllocal_install uninstall warn_if_old_packlist); -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; my $Is_VMS = $^O eq 'VMS'; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist.pm index fb9977b761..517f43a659 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist.pm @@ -2,7 +2,7 @@ package ExtUtils::Liblist; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; use File::Spec; require ExtUtils::Liblist::Kid; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm index 380d4f8a9a..694a595190 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm @@ -9,7 +9,7 @@ use 5.006; # Broken out of MakeMaker from version 4.11 use strict; -our $VERSION = 6.55_02; +our $VERSION = 6.55_03; use Config; use Cwd 'cwd'; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM.pm index 4694f3f1c8..4359837412 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM.pm @@ -3,7 +3,7 @@ package ExtUtils::MM; use strict; use ExtUtils::MakeMaker::Config; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::Liblist; require ExtUtils::MakeMaker; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_AIX.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_AIX.pm index 0f27d177c9..fbe385936d 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_AIX.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_AIX.pm @@ -1,7 +1,7 @@ package ExtUtils::MM_AIX; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Unix; our @ISA = qw(ExtUtils::MM_Unix); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm index a7afe2069c..50694cfa9c 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm @@ -1,7 +1,7 @@ package ExtUtils::MM_Any; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; use Carp; use File::Spec; @@ -2279,6 +2279,8 @@ sub _PREREQ_PRINT { Implements PRINT_PREREQ, a slightly different version of PREREQ_PRINT added by Redhat to, I think, support generating RPMs from Perl modules. +Should not include BUILD_REQUIRES as RPMs do not incluide them. + Refactored out of MakeMaker->new(). =end private @@ -2288,7 +2290,7 @@ Refactored out of MakeMaker->new(). sub _PRINT_PREREQ { my $self = shift; - my $prereqs= $self->_all_prereqs; + my $prereqs= $self->{PREREQ_PM}; my @prereq = map { [$_, $prereqs->{$_}] } keys %$prereqs; if ( $self->{MIN_PERL_VERSION} ) { diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_BeOS.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_BeOS.pm index 168d23dfd7..c2904df7f2 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_BeOS.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_BeOS.pm @@ -26,7 +26,7 @@ require ExtUtils::MM_Any; require ExtUtils::MM_Unix; our @ISA = qw( ExtUtils::MM_Any ExtUtils::MM_Unix ); -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; =item os_flavor diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Cygwin.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Cygwin.pm index 9cc7522ac3..f9982ab655 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Cygwin.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Cygwin.pm @@ -9,7 +9,7 @@ require ExtUtils::MM_Unix; require ExtUtils::MM_Win32; our @ISA = qw( ExtUtils::MM_Unix ); -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; =head1 NAME diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_DOS.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_DOS.pm index 84bedeada8..da9bea27b7 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_DOS.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_DOS.pm @@ -2,7 +2,7 @@ package ExtUtils::MM_DOS; use strict; -our $VERSION = 6.55_02; +our $VERSION = 6.55_03; require ExtUtils::MM_Any; require ExtUtils::MM_Unix; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Darwin.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Darwin.pm index d26c0a10f2..3999253f74 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Darwin.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Darwin.pm @@ -7,7 +7,7 @@ BEGIN { our @ISA = qw( ExtUtils::MM_Unix ); } -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; =head1 NAME diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_MacOS.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_MacOS.pm index bab7ab92bb..0be95b2143 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_MacOS.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_MacOS.pm @@ -2,7 +2,7 @@ package ExtUtils::MM_MacOS; use strict; -our $VERSION = 6.55_02; +our $VERSION = 6.55_03; sub new { die <<'UNSUPPORTED'; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_NW5.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_NW5.pm index 950f1759dd..4bc7a85750 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_NW5.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_NW5.pm @@ -22,7 +22,7 @@ use strict; use ExtUtils::MakeMaker::Config; use File::Basename; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Win32; our @ISA = qw(ExtUtils::MM_Win32); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_OS2.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_OS2.pm index 73c1819f07..c825e4305d 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_OS2.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_OS2.pm @@ -5,7 +5,7 @@ use strict; use ExtUtils::MakeMaker qw(neatvalue); use File::Spec; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Any; require ExtUtils::MM_Unix; @@ -83,7 +83,8 @@ $self->{BASEEXT}.def: Makefile.PL # print "emximp -o tmpimp$Config::Config{lib_ext} tmpimp.imp\n"; system "emximp -o tmpimp$Config::Config{lib_ext} tmpimp.imp" and die "Cannot make import library: $!, \$?=$?"; - unlink <tmp_imp/*>; + # May be running under miniperl, so have no glob... + eval "unlink <tmp_imp/*>; 1" or system "rm tmp_imp/*"; system "cd tmp_imp; $Config::Config{ar} x ../tmpimp$Config::Config{lib_ext}" and die "Cannot extract import objects: $!, \$?=$?"; } diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_QNX.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_QNX.pm index df6e5719ad..6c2f94193d 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_QNX.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_QNX.pm @@ -1,7 +1,7 @@ package ExtUtils::MM_QNX; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Unix; our @ISA = qw(ExtUtils::MM_Unix); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_UWIN.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_UWIN.pm index d3f2949e7d..182632adc2 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_UWIN.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_UWIN.pm @@ -1,7 +1,7 @@ package ExtUtils::MM_UWIN; use strict; -our $VERSION = 6.55_02; +our $VERSION = 6.55_03; require ExtUtils::MM_Unix; our @ISA = qw(ExtUtils::MM_Unix); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm index dc09eca68b..5c584ce0b1 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm @@ -15,7 +15,7 @@ use ExtUtils::MakeMaker qw($Verbose neatvalue); # If we make $VERSION an our variable parse_version() breaks use vars qw($VERSION); -$VERSION = '6.55_02'; +$VERSION = '6.55_03'; require ExtUtils::MM_Any; our @ISA = qw(ExtUtils::MM_Any); @@ -2611,6 +2611,10 @@ It will return the string "undef" if it can't figure out what $VERSION is. $VERSION should be for all to see, so C<our $VERSION> or plain $VERSION are okay, but C<my $VERSION> is not. +C<<package Foo VERSION>> is also checked for. The first version +declaration found is used, but this may change as it differs from how +Perl does it. + parse_version() will try to C<use version> before checking for C<$VERSION> so the following will work. @@ -2631,29 +2635,37 @@ sub parse_version { next if $inpod || /^\s*#/; chop; next if /^\s*(if|unless)/; - next unless m{(?<!\\) ([\$*]) (([\w\:\']*) \bVERSION)\b .* =}x; - my $eval = qq{ - package ExtUtils::MakeMaker::_version; - no strict; - BEGIN { eval { - # Ensure any version() routine which might have leaked - # into this package has been deleted. Interferes with - # version->import() - undef *version; - require version; - "version"->import; - } } - - local $1$2; - \$$2=undef; - do { - $_ + if ( m{^ \s* package \s+ \w[\w\:\']* \s+ (v?[0-9._]+) \s* ; }x ) { + local $^W = 0; + $result = $1; + } + elsif ( m{(?<!\\) ([\$*]) (([\w\:\']*) \bVERSION)\b .* =}x ) { + my $eval = qq{ + package ExtUtils::MakeMaker::_version; + no strict; + BEGIN { eval { + # Ensure any version() routine which might have leaked + # into this package has been deleted. Interferes with + # version->import() + undef *version; + require version; + "version"->import; + } } + + local $1$2; + \$$2=undef; + do { + $_ + }; + \$$2; }; - \$$2; - }; - local $^W = 0; - $result = eval($eval); ## no critic - warn "Could not eval '$eval' in $parsefile: $@" if $@; + local $^W = 0; + $result = eval($eval); ## no critic + warn "Could not eval '$eval' in $parsefile: $@" if $@; + } + else { + next; + } last if defined $result; } close $fh; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VMS.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VMS.pm index 492a12071a..a7636051c9 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VMS.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VMS.pm @@ -15,7 +15,7 @@ BEGIN { use File::Basename; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Any; require ExtUtils::MM_Unix; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VOS.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VOS.pm index 3a7ec87ec8..db08337cb1 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VOS.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_VOS.pm @@ -1,7 +1,7 @@ package ExtUtils::MM_VOS; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Unix; our @ISA = qw(ExtUtils::MM_Unix); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win32.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win32.pm index 15d4b3d19d..5f5918ec68 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win32.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win32.pm @@ -27,7 +27,7 @@ use ExtUtils::MakeMaker qw( neatvalue ); require ExtUtils::MM_Any; require ExtUtils::MM_Unix; our @ISA = qw( ExtUtils::MM_Any ExtUtils::MM_Unix ); -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; $ENV{EMXSHELL} = 'sh'; # to run `commands` diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win95.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win95.pm index 0c04f83006..b35bda2d41 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win95.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Win95.pm @@ -2,7 +2,7 @@ package ExtUtils::MM_Win95; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require ExtUtils::MM_Win32; our @ISA = qw(ExtUtils::MM_Win32); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MY.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MY.pm index c1a8c94a69..ef9c545811 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MY.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MY.pm @@ -3,7 +3,7 @@ package ExtUtils::MY; use strict; require ExtUtils::MM; -our $VERSION = 6.55_02; +our $VERSION = 6.55_03; our @ISA = qw(ExtUtils::MM); { diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm index 893c0bfb81..72f59aba77 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm @@ -18,7 +18,7 @@ our @Overridable; my @Prepend_parent; my %Recognized_Att_Keys; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; # Emulate something resembling CVS $Revision$ (our $Revision = $VERSION) =~ s{_}{}; @@ -747,16 +747,17 @@ sub _MakeMaker_Parameters_section { # MakeMaker Parameters: END - # CPAN.pm takes prereqs from this field in 'Makefile' - # and does not know about BUILD_REQUIRES - if( $att->{PREREQ_PM} || $att->{BUILD_REQUIRES} ) { - %{$att->{'PREREQ_PM'}} = (%{$att->{'PREREQ_PM'}||{}}, %{$att->{'BUILD_REQUIRES'}||{}}); - } - foreach my $key (sort keys %$att){ next if $key eq 'ARGS'; + my ($v) = neatvalue($att->{$key}); + if ($key eq 'PREREQ_PM') { + # CPAN.pm takes prereqs from this field in 'Makefile' + # and does not know about BUILD_REQUIRES + $v = neatvalue({ %{ $att->{PREREQ_PM} || {} }, %{ $att->{BUILD_REQUIRES} || {} } }); + } else { + $v = neatvalue($att->{$key}); + } - my($v) = neatvalue($att->{$key}); $v =~ s/(CODE|HASH|ARRAY|SCALAR)\([\dxa-f]+\)/$1\(...\)/; $v =~ tr/\n/ /s; push @result, "# $key => $v"; @@ -1531,7 +1532,7 @@ to run your distribution. This will go into the C<configure_requires> field of your F<META.yml>. -Defaults to C<{ "ExtUtils::MakeMaker" => 0 }> +Defaults to C<<< { "ExtUtils::MakeMaker" => 0 } >>> The format is the same as PREREQ_PM. @@ -2342,19 +2343,16 @@ Instead of specifying the VERSION in the Makefile.PL you can let MakeMaker parse a file to determine the version number. The parsing routine requires that the file named by VERSION_FROM contains one single line to compute the version number. The first line in the file -that contains the regular expression - - /([\$*])(([\w\:\']*)\bVERSION)\b.*\=/ - -will be evaluated with eval() and the value of the named variable -B<after> the eval() will be assigned to the VERSION attribute of the -MakeMaker object. The following lines will be parsed o.k.: - - $VERSION = '1.00'; - *VERSION = \'1.01'; - ($VERSION) = q$Revision$ =~ /(\d+)/g; - $FOO::VERSION = '1.10'; - *FOO::VERSION = \'1.11'; +that contains something like a $VERSION assignment or C<package Name +VERSION> will be used. The following lines will be parsed o.k.: + + # Good + package Foo::Bar 1.23; # 1.23 + $VERSION = '1.00'; # 1.00 + *VERSION = \'1.01'; # 1.01 + ($VERSION) = q$Revision$ =~ /(\d+)/g; # The digits in $Revision$ + $FOO::VERSION = '1.10'; # 1.10 + *FOO::VERSION = \'1.11'; # 1.11 but these will fail: diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker/Config.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker/Config.pm index 9c99f7d1b2..dee7100dd3 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker/Config.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker/Config.pm @@ -2,7 +2,7 @@ package ExtUtils::MakeMaker::Config; use strict; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; use Config (); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mkbootstrap.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mkbootstrap.pm index f1b47f6750..21163bbd97 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mkbootstrap.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mkbootstrap.pm @@ -3,7 +3,7 @@ package ExtUtils::Mkbootstrap; # There's just too much Dynaloader incest here to turn on strict vars. use strict 'refs'; -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; require Exporter; our @ISA = ('Exporter'); diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mksymlists.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mksymlists.pm index 9b133f74a7..29bd558690 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mksymlists.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/Mksymlists.pm @@ -10,7 +10,7 @@ use Config; our @ISA = qw(Exporter); our @EXPORT = qw(&Mksymlists); -our $VERSION = '6.55_02'; +our $VERSION = '6.55_03'; sub Mksymlists { my(%spec) = @_; diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/testlib.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/testlib.pm index b1231e2c4c..2efe6e7f7c 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/testlib.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/testlib.pm @@ -3,7 +3,7 @@ package ExtUtils::testlib; use strict; use warnings; -our $VERSION = 6.55_02; +our $VERSION = 6.55_03; use Cwd; use File::Spec; diff --git a/cpan/ExtUtils-MakeMaker/t/00compile.t b/cpan/ExtUtils-MakeMaker/t/00compile.t index 743bd9980a..f392276623 100644 --- a/cpan/ExtUtils-MakeMaker/t/00compile.t +++ b/cpan/ExtUtils-MakeMaker/t/00compile.t @@ -15,9 +15,10 @@ BEGIN { chdir ".."; my $manifest = "MANIFEST"; open(my $manifest_fh, "<", $manifest) or die "Can't open $manifest: $!"; -my @modules = map { m{^lib/(\S+)}; $1 } +my @modules = map { m{^lib/(\S+)}; $1 } grep { m{^lib/\S+\.pm} } <$manifest_fh>; + chomp @modules; close $manifest_fh; diff --git a/cpan/ExtUtils-MakeMaker/t/Liblist.t b/cpan/ExtUtils-MakeMaker/t/Liblist.t index f8d3023a1d..7161fd373b 100644 --- a/cpan/ExtUtils-MakeMaker/t/Liblist.t +++ b/cpan/ExtUtils-MakeMaker/t/Liblist.t @@ -1,14 +1,6 @@ #!/usr/bin/perl -w -BEGIN { - if( $ENV{PERL_CORE} ) { - chdir 't' if -d 't'; - unshift @INC, '../lib'; - } - else { - unshift @INC, 't/lib'; - } -} +use lib 't/lib'; chdir 't'; use strict; diff --git a/cpan/ExtUtils-MakeMaker/t/basic.t b/cpan/ExtUtils-MakeMaker/t/basic.t index 0a51e4956f..1842a1c839 100644 --- a/cpan/ExtUtils-MakeMaker/t/basic.t +++ b/cpan/ExtUtils-MakeMaker/t/basic.t @@ -11,7 +11,7 @@ use strict; use Config; use ExtUtils::MakeMaker; -use Test::More tests => 79; +use Test::More tests => 80; use MakeMaker::Test::Utils; use MakeMaker::Test::Setup::BFD; use File::Find; @@ -89,6 +89,7 @@ like( $ppd_html, ' <AUTHOR>' ); like( $ppd_html, qr{^\s*<IMPLEMENTATION>}m, ' <IMPLEMENTATION>'); like( $ppd_html, qr{^\s*<REQUIRE NAME="strict::" />}m, ' <REQUIRE>' ); +unlike( $ppd_html, qr{^\s*<REQUIRE NAME="warnings::" />}m, 'no <REQUIRE> for build_require' ); my $archname = $Config{archname}; if( $] >= 5.008 ) { @@ -258,7 +259,7 @@ distribution_type: module configure_requires: ExtUtils::MakeMaker: 0 build_requires: - ExtUtils::MakeMaker: 0 + warnings: 0 requires: strict: 0 no_index: diff --git a/cpan/ExtUtils-MakeMaker/t/dir_target.t b/cpan/ExtUtils-MakeMaker/t/dir_target.t index 0485469f20..6744093de7 100644 --- a/cpan/ExtUtils-MakeMaker/t/dir_target.t +++ b/cpan/ExtUtils-MakeMaker/t/dir_target.t @@ -1,8 +1,6 @@ #!/usr/bin/perl -w -BEGIN { - unshift @INC, 't/lib/'; -} +use lib 't/lib'; chdir 't'; use Test::More tests => 1; diff --git a/cpan/ExtUtils-MakeMaker/t/lib/MakeMaker/Test/Setup/BFD.pm b/cpan/ExtUtils-MakeMaker/t/lib/MakeMaker/Test/Setup/BFD.pm index 9745656f63..82dd030938 100644 --- a/cpan/ExtUtils-MakeMaker/t/lib/MakeMaker/Test/Setup/BFD.pm +++ b/cpan/ExtUtils-MakeMaker/t/lib/MakeMaker/Test/Setup/BFD.pm @@ -37,6 +37,7 @@ WriteMakefile( VERSION_FROM => 'lib/Big/Dummy.pm', EXE_FILES => [qw(bin/program)], PREREQ_PM => { strict => 0 }, + BUILD_REQUIRES => { warnings => 0 }, ABSTRACT_FROM => 'lib/Big/Dummy.pm', AUTHOR => 'Michael G Schwern <schwern@pobox.com>', ); diff --git a/cpan/ExtUtils-MakeMaker/t/parse_version.t b/cpan/ExtUtils-MakeMaker/t/parse_version.t index ca1048cb4b..858e294181 100644 --- a/cpan/ExtUtils-MakeMaker/t/parse_version.t +++ b/cpan/ExtUtils-MakeMaker/t/parse_version.t @@ -36,6 +36,7 @@ my %versions = (q[$VERSION = '1.00'] => '1.00', '$VERSION = sprintf("%d.%03d", q$Revision: 3.74 $ =~ /(\d+)\.(\d+)/);' => '3.074', '$VERSION = substr(q$Revision: 2.8 $, 10) + 2 . "";' => '4.8', + ); if( $Has_Version ) { @@ -43,10 +44,40 @@ if( $Has_Version ) { $versions{q[$VERSION = qv("1.2.3")]} = qv("1.2.3"); } +if( $] >= 5.011001 ) { + $versions{'package Foo 1.23;' } = '1.23'; + $versions{'package Foo::Bar 1.23;' } = '1.23'; + $versions{'package Foo v1.2.3;' } = 'v1.2.3'; + $versions{'package Foo::Bar v1.2.3;' } = 'v1.2.3'; + $versions{' package Foo::Bar 1.23 ;' } = '1.23'; + $versions{"package Foo'Bar 1.23;" } = '1.23'; + $versions{"package Foo::Bar 1.2.3;" } = '1.2.3'; + $versions{'package Foo 1.230;' } = '1.230'; + $versions{'package Foo 1.23_01;' } = '1.23_01'; + $versions{'package Foo v1.23_01;' } = 'v1.23_01'; + $versions{q["package Foo 1.23"]} = 'undef'; + $versions{<<'END'} = '1.23'; +package Foo 1.23; +our $VERSION = 2.34; +END + + $versions{<<'END'} = '2.34'; +our $VERSION = 2.34; +package Foo 1.23; +END + + $versions{<<'END'} = '2.34'; +package Foo::100; +our $VERSION = 2.34; +END +} + plan tests => (2 * keys %versions) + 4; -while( my($code, $expect) = each %versions ) { - is( parse_version_string($code), $expect, $code ); +for my $code ( sort keys %versions ) { + my $expect = $versions{$code}; + (my $label = $code) =~ s/\n/\\n/g; + is( parse_version_string($code), $expect, $label ); } @@ -60,9 +91,9 @@ sub parse_version_string { $_ = 'foo'; my $version = MM->parse_version('VERSION.tmp'); is( $_, 'foo', '$_ not leaked by parse_version' ); - + unlink "VERSION.tmp"; - + return $version; } @@ -73,7 +104,7 @@ sub parse_version_string { SKIP: { skip "need version.pm", 4 unless $Has_Version; is parse_version_string(q[ $VERSION = '1.00'; sub version { $VERSION } ]), - '1.00'; + '1.00', "eval 'sub version {...} in version string"; is parse_version_string(q[ use version; $VERSION = version->new("1.2.3") ]), - qv("1.2.3"); + qv("1.2.3"), "version.pm not confused by version sub"; } |