Use Module::Install::CheckConflicts rather than doing it ourself
[gitmo/Moose.git] / Makefile.PL
CommitLineData
db90f764 1use strict;
2use warnings;
f0374fd6 3use inc::Module::Install 0.98;
2e503ae9 4use Module::Install::AuthorRequires;
962d7364 5use 5.008003;
db90f764 6
4ff140fe 7check_broken_extratests();
0161e7d4 8
db90f764 9name 'Moose';
962d7364 10perl_version '5.008003';
db90f764 11all_from 'lib/Moose.pm';
12license 'perl';
13
4c0dcbca 14# Use the xt/author/test-my-dependents.t test to figure
15# out what on CPAN will break with the latest Moose, then update this
16# before a release.
17my %conflicts = (
18 'Catalyst' => '5.80017',
19 'Devel::REPL' => '1.003008',
20 'Fey::ORM' => '0.23',
21 'File::ChangeNotify' => '0.15',
22 'KiokuDB' => '0.41',
23 'MooseX::Aliases' => '0.07',
24 'MooseX::AlwaysCoerce' => '0.05',
25 'MooseX::AttributeHelpers' => '0.22',
26 'MooseX::AttributeInflate' => '0.02',
27 'MooseX::Attribute::Prototype' => '0.10',
28 'MooseX::ClassAttribute' => '0.13',
29 'MooseX::FollowPBP' => '0.02',
30 'MooseX::HasDefaults' => '0.02',
31 'MooseX::InstanceTracking' => '0.04',
32 'MooseX::LazyRequire' => '0.05',
33 'MooseX::MethodAttributes' => '0.22',
34 'MooseX::NonMoose' => '0.13',
35 'MooseX::Params::Validate' => '0.05',
36 'MooseX::POE' => '0.205',
37 'MooseX::Role::Cmd' => '0.06',
38 'MooseX::Role::WithOverloading' => '0.07',
39 'MooseX::SemiAffordanceAccessor' => '0.05',
40 'MooseX::Singleton' => '0.24',
41 'MooseX::StrictConstructor' => '0.08',
42 'MooseX::Types' => '0.19',
43 'MooseX::UndefTolerant' => '0.04',
44 'namespace::autoclean' => '0.08',
45 'Pod::Elemental' => '0.093280',
46);
47
48check_conflicts(%conflicts);
49
db90f764 50requires 'Carp';
40e7fd16 51requires 'Class::MOP' => '1.05';
40cb86f7 52requires 'Data::OptList' => '0';
53requires 'List::MoreUtils' => '0.12';
ec1ee84b 54requires 'Package::DeprecationManager' => '0.04';
40cb86f7 55requires 'Scalar::Util' => '1.19';
56requires 'Sub::Exporter' => '0.980';
57requires 'Sub::Name' => '0';
58requires 'Task::Weaken' => '0';
59requires 'Try::Tiny' => '0.02';
25374f01 60
87f55e33 61test_requires 'Test::More' => '0.88';
c0026a42 62test_requires 'Test::Exception' => '0.27';
db90f764 63
2e503ae9 64author_requires 'File::Find::Rule';
65author_requires 'Module::Info';
c7885929 66author_requires 'Test::Inline';
d68b5280 67author_requires 'Test::NoTabs';
c7885929 68author_requires 'Test::Output';
69author_requires 'Test::Pod::Coverage';
70author_requires 'Test::Spelling';
2e503ae9 71
4ff140fe 72if ( is_maintainer() ) {
c3ad9761 73 system( $^X, 'author/extract-inline-tests' );
de341d84 74}
75
6fb58c0d 76tests_recursive();
29772efc 77
6ee1960e 78repository 'git://git.moose.perl.org/Moose.git';
f0374fd6 79add_metadata(x_authority => 'cpan:STEVAN');
6ee1960e 80
db90f764 81WriteAll();
82
4ff140fe 83sub is_maintainer {
84 return $Module::Install::AUTHOR || $ENV{IS_MAINTAINER};
85}
86
87sub check_broken_extratests {
88 return unless is_maintainer();
89
90 if ( exists $Module::Install::ExtraTests::{VERSION} && Module::Install::ExtraTests->VERSION < 0.007 ) {
91 print STDERR <<'EOR';
92You have a broken version of Module::Install::ExtraTests installed.
93Please upgrade to version 0.007 or newer and re-run Makefile.PL
94EOR
95 exit 0;
96 }
97}