From: Steffen Mueller Date: Sun, 18 Apr 2010 14:24:20 +0000 (+0200) Subject: EU::MakeMaker shouldn't warn about prereqs in core X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=175046355f07701;p=p5sagit%2Fp5-mst-13.2.git EU::MakeMaker shouldn't warn about prereqs in core This silences warnings about missing prerequisites when part of a perl core build. Triggered by #74442. --- diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm index 4422b68..22ede40 100644 --- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm +++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm @@ -467,14 +467,16 @@ END if (!$installed_file) { warn sprintf "Warning: prerequisite %s %s not found.\n", $prereq, $required_version - unless $self->{PREREQ_FATAL}; + unless $self->{PREREQ_FATAL} + or $ENV{PERL_CORE}; $unsatisfied{$prereq} = 'not installed'; } elsif ($pr_version < $required_version ){ warn sprintf "Warning: prerequisite %s %s not found. We have %s.\n", $prereq, $required_version, ($pr_version || 'unknown version') - unless $self->{PREREQ_FATAL}; + unless $self->{PREREQ_FATAL} + or $ENV{PERL_CORE}; $unsatisfied{$prereq} = $required_version ? $required_version : 'unknown version' ; } diff --git a/cpan/ExtUtils-MakeMaker/t/prereq.t b/cpan/ExtUtils-MakeMaker/t/prereq.t index cd5d18d..4a537a5 100644 --- a/cpan/ExtUtils-MakeMaker/t/prereq.t +++ b/cpan/ExtUtils-MakeMaker/t/prereq.t @@ -35,6 +35,9 @@ ok( chdir 'Big-Dummy', "chdir'd to Big-Dummy" ) || local $SIG{__WARN__} = sub { $warnings .= join '', @_; }; + # prerequisite warnings are disbled while building the perl core: + local %ENV; + delete $ENV{PERL_CORE}; WriteMakefile( NAME => 'Big::Dummy',