From: David Golden Date: Sat, 8 Jan 2011 21:19:51 +0000 (-0500) Subject: Bootstrap Module::Build in Makefile.PL X-Git-Tag: 1.008004~18 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2Flocal-lib.git;a=commitdiff_plain;h=135193f4d788916c723ab46c2800a99ad08fe33e Bootstrap Module::Build in Makefile.PL Now that Module::Build supports PERL_MB_OPT, it can be bootstrapped just like ExtUtils::MakeMaker is. This is a critical change to support CPAN.pm being able to bootstrap local::lib on old Perls. (Tested on 5.8.1) --- diff --git a/Changes b/Changes index 9ed33dd..1a6067c 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,7 @@ Revision history for local::lib + - Bootstrap Module::Build just like ExtUtils::MakeMaker + 1.008000 - Remove redundant prereqs now that Module::Build 0.36 is required - Makefile.PL avoids CPAN client configuration when not required diff --git a/Makefile.PL b/Makefile.PL index 11f376c..686297b 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -88,6 +88,9 @@ DEATH system($^X, '-MExtUtils::Install 1.43', '-e1'); my $eui = $? >> 8; + system($^X, '-MModule::Build 0.36', '-e1'); + my $mb = $? >> 8; + system($^X, '-MCPAN 1.82', '-e1'); my $cpan = $? >> 8; my $cpan_command = ''; @@ -134,6 +137,9 @@ DEATH if ($eui) { $cpan_command .= 'install("ExtUtils::Install"); '; } + if ($mb) { + $cpan_command .= 'install("Module::Build"); '; + } if ($cpan) { $cpan_command .= 'force("install","CPAN"); '; }