X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2FImport-Into.git;a=blobdiff_plain;f=Makefile.PL;h=069e38f49a580ae89ef5fc8f3d7e55f8d08dea87;hp=7761e0918c5a78207aae37e90bdc84b54937fa48;hb=ba6a6452c916852159578e58761a827427a27a52;hpb=88f5410d1c9c6342d8baac0b9024c395756a857a diff --git a/Makefile.PL b/Makefile.PL index 7761e09..069e38f 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -42,12 +42,11 @@ my %META = ( ); my %MM_ARGS = ( - realclean => { FILES => [ 'Distar/', 'MANIFEST*' ] }, ); -############################################################################## +## BOILERPLATE ############################################################### require ExtUtils::MakeMaker; -(do 'maint/Makefile.PL.include' or die $@) unless -f 'META.yml'; +(do './maint/Makefile.PL.include' or die $@) unless -f 'META.yml'; # have to do this since old EUMM dev releases miss the eval $VERSION line my $eumm_version = eval $ExtUtils::MakeMaker::VERSION; @@ -56,8 +55,10 @@ my $mymeta_broken = $mymeta && $eumm_version < 6.57_07; ($MM_ARGS{NAME} = $META{name}) =~ s/-/::/g; ($MM_ARGS{VERSION_FROM} = "lib/$MM_ARGS{NAME}.pm") =~ s{::}{/}g; -$MM_ARGS{LICENSE} = $META{license} - if $eumm_version >= 6.30; +$META{license} = [ $META{license} ] + if $META{license} && !ref $META{license}; +$MM_ARGS{LICENSE} = $META{license}[0] + if $META{license} && $eumm_version >= 6.30; $MM_ARGS{NO_MYMETA} = 1 if $mymeta_broken; $MM_ARGS{META_ADD} = { 'meta-spec' => { version => 2 }, %META } @@ -84,3 +85,4 @@ delete $MM_ARGS{CONFIGURE_REQUIRES} if $eumm_version < 6.51_03; ExtUtils::MakeMaker::WriteMakefile(%MM_ARGS); +## END BOILERPLATE ###########################################################