X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=Makefile.PL;h=df1da8338d41bdf99890568f6c66a88564c566d4;hb=9720202815dbafee0d9e944e3f8258d4aca446d4;hp=b5c23680e04bee25e558ba8a7648025caad1fe16;hpb=a08e7b00d0c4670291fdf7bc4e19438da3000723;p=dbsrgits%2FDBIx-Class.git diff --git a/Makefile.PL b/Makefile.PL index b5c2368..df1da83 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -146,9 +146,15 @@ if ($Module::Install::AUTHOR and ! $ENV{MAKELEVEL}) { warn "\nIgnoring unrecognized option(s): @ARGV\n\n"; } + # We need the MM facilities to generate the pieces for the final MM run. + # Just instantiate a throaway object here + my $mm_proto = ExtUtils::MakeMaker->new({ + NAME => Meta->name || die 'The Module::Install metadata must be available at this point but is not - did you rearrange the Makefile.PL...?', + }); + require File::Spec; # string-eval, not do(), because we need to provide the - # $reqs and $*_requires lexicals to the included file + # $mm_proto, $reqs and $*_requires lexicals to the included file # (some includes *do* modify $reqs above) for my $inc (sort glob ( File::Spec->catfile('maint', 'Makefile.PL.inc', '*') ) ) { my $src = do { local (@ARGV, $/) = $inc; <> } or die $!;