2 use warnings FATAL => 'all';
6 name => 'Class-C3-Componentised',
9 configure => { requires => {
10 'ExtUtils::MakeMaker' => 0,
12 build => { requires => {
16 'Test::Exception' => '0.31',
17 'Test::More' => '0.96',
23 'MRO::Compat' => '0.09',
24 'Class::Inspector' => '1.32',
25 # we don't actually need Class::C3. MRO::Compat loads it on 5.8. On 5.10
26 # it isn't needed. However, some existing code relies on us loading
27 # Class::C3. We don't want to break it just yet. Therefore we depend
28 # directly on Class::C3 as well.
29 'Class::C3' => '0.20',
34 'Test::Pod' => '1.14',
35 'Test::Pod::Coverage' => '1.04',
41 url => 'git://git.shadowcat.co.uk/p5sagit/Class-C3-Componentised.git',
42 web => 'https://github.com/p5sagit/Class-C3-Componentised',
46 web => 'https://rt.cpan.org/Public/Dist/Display.html?Name=Class-C3-Componentised',
47 mailto => 'bug-Class-C3-Componentised@rt.cpan.org',
49 license => [ 'http://dev.perl.org/licenses/' ],
52 directory => [ 't', 'xt' ]
54 x_authority => "cpan:FREW",
56 x_static_install => 1,
61 ## BOILERPLATE ###############################################################
62 require ExtUtils::MakeMaker;
63 (do './maint/Makefile.PL.include' or die $@) unless -f 'META.yml';
65 # have to do this since old EUMM dev releases miss the eval $VERSION line
66 my $eumm_version = eval $ExtUtils::MakeMaker::VERSION;
67 my $mymeta = $eumm_version >= 6.57_02;
68 my $mymeta_broken = $mymeta && $eumm_version < 6.57_07;
70 ($MM_ARGS{NAME} = $META{name}) =~ s/-/::/g;
71 ($MM_ARGS{VERSION_FROM} = "lib/$MM_ARGS{NAME}.pm") =~ s{::}{/}g;
72 $META{license} = [ $META{license} ]
73 if $META{license} && !ref $META{license};
74 $MM_ARGS{LICENSE} = $META{license}[0]
75 if $META{license} && $eumm_version >= 6.30;
76 $MM_ARGS{NO_MYMETA} = 1
78 $MM_ARGS{META_ADD} = { 'meta-spec' => { version => 2 }, %META }
80 $MM_ARGS{PL_FILES} ||= {};
81 $MM_ARGS{NORECURS} = 1
82 if not exists $MM_ARGS{NORECURS};
84 for (qw(configure build test runtime)) {
85 my $key = $_ eq 'runtime' ? 'PREREQ_PM' : uc $_.'_REQUIRES';
86 my $r = $MM_ARGS{$key} = {
87 %{$META{prereqs}{$_}{requires} || {}},
88 %{delete $MM_ARGS{$key} || {}},
90 defined $r->{$_} or delete $r->{$_} for keys %$r;
93 $MM_ARGS{MIN_PERL_VERSION} = delete $MM_ARGS{PREREQ_PM}{perl} || 0;
95 delete $MM_ARGS{MIN_PERL_VERSION}
96 if $eumm_version < 6.47_01;
97 $MM_ARGS{BUILD_REQUIRES} = {%{$MM_ARGS{BUILD_REQUIRES}}, %{delete $MM_ARGS{TEST_REQUIRES}}}
98 if $eumm_version < 6.63_03;
99 $MM_ARGS{PREREQ_PM} = {%{$MM_ARGS{PREREQ_PM}}, %{delete $MM_ARGS{BUILD_REQUIRES}}}
100 if $eumm_version < 6.55_01;
101 delete $MM_ARGS{CONFIGURE_REQUIRES}
102 if $eumm_version < 6.51_03;
104 ExtUtils::MakeMaker::WriteMakefile(%MM_ARGS);
105 ## END BOILERPLATE ###########################################################