In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/34861f291d6c548304b74dfc30ff27447f1b582f?hp=a8b2c106f7c4e82cbfd4fd5b0032b50f9499a67e>

- Log -----------------------------------------------------------------
commit 34861f291d6c548304b74dfc30ff27447f1b582f
Author: Chris Williams <ch...@bingosnet.co.uk>
Date:   Tue Oct 27 10:07:35 2009 +0000

    Update CPANPLUS to cpan version 0.89_05
    
      Changes for 0.89_05     Tue Oct 27 09:24:55 2009
      ================================================
      * Change the way editing config files is called. This fixes RT #50832,
        reported by Dave Golden
      * Issue a warning in the shell if we are on MSWin32, don't have IPC::Run
        installed and are writing a log file.
      * Apply several patches from Alexandr Ciornii (CHORNY) RT #48636 that
        add toolchain versions listing to tester reports.
-----------------------------------------------------------------------

Summary of changes:
 Porting/Maintainers.pl                             |    2 +-
 cpan/CPANPLUS/lib/CPANPLUS.pm                      |    2 +-
 cpan/CPANPLUS/lib/CPANPLUS/Internals.pm            |    2 +-
 .../lib/CPANPLUS/Internals/Constants/Report.pm     |   52 ++++++++++++++++++++
 cpan/CPANPLUS/lib/CPANPLUS/Internals/Report.pm     |    3 +
 cpan/CPANPLUS/lib/CPANPLUS/Shell/Default.pm        |   13 ++++-
 cpan/CPANPLUS/t/40_CPANPLUS-Internals-Report.t     |   10 ++++
 7 files changed, 79 insertions(+), 5 deletions(-)

diff --git a/Porting/Maintainers.pl b/Porting/Maintainers.pl
index 6a6d8b9..12d816a 100755
--- a/Porting/Maintainers.pl
+++ b/Porting/Maintainers.pl
@@ -423,7 +423,7 @@ use File::Glob qw(:case);
     'CPANPLUS' =>
        {
        'MAINTAINER'    => 'kane',
-       'DISTRIBUTION'  => 'BINGOS/CPANPLUS-0.89_04.tar.gz',
+       'DISTRIBUTION'  => 'BINGOS/CPANPLUS-0.89_05.tar.gz',
        'FILES'         => q[cpan/CPANPLUS],
        'EXCLUDED'      => [ qr{^inc/},
                             qr{^t/dummy-.*\.hidden$},
diff --git a/cpan/CPANPLUS/lib/CPANPLUS.pm b/cpan/CPANPLUS/lib/CPANPLUS.pm
index 20f5f8a..5fc9ec8 100644
--- a/cpan/CPANPLUS/lib/CPANPLUS.pm
+++ b/cpan/CPANPLUS/lib/CPANPLUS.pm
@@ -13,7 +13,7 @@ BEGIN {
     use vars        qw( @EXPORT @ISA $VERSION );
     @EXPORT     =   qw( shell fetch get install );
     @ISA        =   qw( Exporter );
-    $VERSION = "0.89_04";     #have to hardcode or cpan.org gets unhappy
+    $VERSION = "0.89_05";     #have to hardcode or cpan.org gets unhappy
 }
 
 ### purely for backward compatibility, so we can call it from the commandline:
diff --git a/cpan/CPANPLUS/lib/CPANPLUS/Internals.pm 
b/cpan/CPANPLUS/lib/CPANPLUS/Internals.pm
index 75c7f95..8657941 100644
--- a/cpan/CPANPLUS/lib/CPANPLUS/Internals.pm
+++ b/cpan/CPANPLUS/lib/CPANPLUS/Internals.pm
@@ -42,7 +42,7 @@ use vars q...@isa $VERSION];
             CPANPLUS::Internals::Report
         ];
 
-$VERSION = "0.89_04";
+$VERSION = "0.89_05";
 
 =pod
 
diff --git a/cpan/CPANPLUS/lib/CPANPLUS/Internals/Constants/Report.pm 
b/cpan/CPANPLUS/lib/CPANPLUS/Internals/Constants/Report.pm
index 07f898d..6ad577c 100644
--- a/cpan/CPANPLUS/lib/CPANPLUS/Internals/Constants/Report.pm
+++ b/cpan/CPANPLUS/lib/CPANPLUS/Internals/Constants/Report.pm
@@ -311,6 +311,58 @@ managed to load:
                                 return $str;
                             };
 
+use constant REPORT_TOOLCHAIN_VERSIONS
+                            => sub {
+                                my $mod = shift;
+                                my $cb  = $mod->parent;
+                                #die unless $cb->isa('CPANPLUS::Backend');
+
+                                my @toolchain_modules= qw(
+                                    CPANPLUS
+                                    CPANPLUS::Dist::Build
+                                    Cwd
+                                    ExtUtils::CBuilder
+                                    ExtUtils::Command
+                                    ExtUtils::Install
+                                    ExtUtils::MakeMaker
+                                    ExtUtils::Manifest
+                                    ExtUtils::ParseXS
+                                    File::Spec
+                                    Module::Build
+                                    Test::Harness
+                                    Test::More
+                                    version
+                                );
+
+                                my @toolchain =
+                                          grep { $_ } #module_tree returns '' 
when module is not found
+                                          map { $cb->module_tree($_) }
+                                          sort @toolchain_modules;
+
+                                ### no prereqs?
+                                return '' unless @toolchain;
+
+                                ### toolchain modules
+                                my $str = << ".";
+
+Perl module toolchain versions installed:
+.
+                                $str .= join '', 
+                                        map { sprintf "\t%-30s %8s\n", 
+                                              @$_
+                                        
+                                        } ['Module Name', 'Have'],
+                                          map {
+                                              [ $_->name,
+                                                $_->installed_version,
+                                              ],
+                                        ### might be empty entries in there
+                                        } @toolchain;   
+                                
+                                return $str;
+                            };
+
+
 use constant REPORT_TESTS_SKIPPED 
                             => sub {
                                 return << ".";
diff --git a/cpan/CPANPLUS/lib/CPANPLUS/Internals/Report.pm 
b/cpan/CPANPLUS/lib/CPANPLUS/Internals/Report.pm
index 312a83c..a1fe921 100644
--- a/cpan/CPANPLUS/lib/CPANPLUS/Internals/Report.pm
+++ b/cpan/CPANPLUS/lib/CPANPLUS/Internals/Report.pm
@@ -477,6 +477,9 @@ sub _send_report {
         ### add a list of what modules have been loaded of your prereqs list
         $message .= REPORT_LOADED_PREREQS->($mod);
 
+        ### add a list of versions of toolchain modules
+        $message .= REPORT_TOOLCHAIN_VERSIONS->($mod);
+
         ### the footer
         $message .= REPORT_MESSAGE_FOOTER->();
 
diff --git a/cpan/CPANPLUS/lib/CPANPLUS/Shell/Default.pm 
b/cpan/CPANPLUS/lib/CPANPLUS/Shell/Default.pm
index 5384b6a..fda2548 100644
--- a/cpan/CPANPLUS/lib/CPANPLUS/Shell/Default.pm
+++ b/cpan/CPANPLUS/lib/CPANPLUS/Shell/Default.pm
@@ -26,7 +26,7 @@ local $Data::Dumper::Indent     = 1; # for dumpering from !
 BEGIN {
     use vars        qw[ $VERSION @ISA ];
     @ISA        =   qw[ CPANPLUS::Shell::_Base::ReadLine ];
-    $VERSION = "0.89_04";
+    $VERSION = "0.89_05";
 }
 
 load CPANPLUS::Shell;
@@ -914,6 +914,15 @@ sub _install {
         ### would you like a log file of what happened?
         if( $conf->get_conf('write_install_logs') ) {
 
+            if ( ON_WIN32 and !check_install(
+                              module => 'IPC::Run', version => 0.55 ) 
+               ) {
+               error(loc("IPC::Run version '%1' is required on MSWin32" 
+                         . " in order to capture buffers." 
+                         . " The logfile generated may not contain" 
+                         . " any useful data, until it is installed", 0.55));
+            }
+
             my $dir = File::Spec->catdir(
                             $conf->get_conf('base'),
                             $conf->_get_build('install_log_dir'),
@@ -1264,7 +1273,7 @@ sub _set_conf {
         }->{ $key } || CONFIG_USER;      
 
         my $file = $conf->_config_pm_to_file( $where );
-        system("$editor $file");
+        system($editor,$file);
 
         ### now reload it
         ### disable warnings for this
diff --git a/cpan/CPANPLUS/t/40_CPANPLUS-Internals-Report.t 
b/cpan/CPANPLUS/t/40_CPANPLUS-Internals-Report.t
index d7c2bd8..ecce8a5 100644
--- a/cpan/CPANPLUS/t/40_CPANPLUS-Internals-Report.t
+++ b/cpan/CPANPLUS/t/40_CPANPLUS-Internals-Report.t
@@ -304,6 +304,16 @@ my $map = {
         like($str, qr/\! $ModPrereq\s+\S+\s+\S+/,
                                         "   Proper content found" );
     }
+
+    {   my $clone   = $Mod->clone;
+
+        my $str = REPORT_TOOLCHAIN_VERSIONS->( $clone );
+        
+        like($str, qr/toolchain/,  "Correct message in report" );
+        use Cwd;
+        like($str, qr/Cwd\s+\Q$Cwd::VERSION\E/,
+                                        "Cwd has correct version in report" );
+    }
 }
 
 ### callback tests

--
Perl5 Master Repository

Reply via email to