Allow applying application_role_summation_class_roles using MetaRole.
[gitmo/Moose.git] / Makefile.PL
CommitLineData
db90f764 1use strict;
2use warnings;
47b19570 3use inc::Module::Install;
4a8035cf 4use 5.008001;
db90f764 5
0161e7d4 6check_conflicts();
7
db90f764 8name 'Moose';
4a8035cf 9perl_version '5.008001';
db90f764 10all_from 'lib/Moose.pm';
11license 'perl';
12
db90f764 13requires 'Carp';
137beb98 14requires 'Class::MOP' => '0.92_01';
6a461fc0 15requires 'Data::OptList' => '0';
e8d6f353 16requires 'List::MoreUtils' => '0.12';
6a461fc0 17requires 'Scalar::Util' => '1.19';
091ac4b7 18requires 'Sub::Exporter' => '0.980';
9f2230e9 19requires 'Sub::Name' => '0';
6a461fc0 20requires 'Task::Weaken' => '0';
6c01c148 21requires 'Try::Tiny' => '0.02';
25374f01 22
87f55e33 23test_requires 'Test::More' => '0.88';
c0026a42 24test_requires 'Test::Exception' => '0.27';
db90f764 25
de341d84 26if ( -d '.svn' || -d '.git' || $ENV{IS_MAINTAINER} ) {
c3ad9761 27 system( $^X, 'author/extract-inline-tests' );
de341d84 28}
29
c93fa627 30extra_tests();
6fb58c0d 31tests_recursive();
29772efc 32
db90f764 33WriteAll();
34
0161e7d4 35# Use the cpan-smolder-stable script in the Moose svn root to figure
36# out what on CPAN will break with the latest Moose, then update this
37# before a release.
38sub check_conflicts {
39 my %conflicts = (
e7e33216 40 'MooseX::ClassAttribute' => '0.09',
60dcd0cf 41 'MooseX::Singleton' => '0.19',
22161b6c 42 'MooseX::StrictConstructor' => '0.07',
43 'MooseX::Params::Validate' => '0.05',
ecba226c 44 'Fey::ORM' => '0.23',
0161e7d4 45 );
46
47 my $found = 0;
48 for my $mod ( sort keys %conflicts ) {
49 eval "require $mod";
50 next if $@;
51
52 my $installed = $mod->VERSION();
53 if ( $installed le $conflicts{$mod} ) {
54
55 print <<"EOF";
56
57***
58 This version of Moose conflicts with the version of
59 $mod ($installed) you have installed.
60
61 You will need to upgrade $mod after installing
62 this version of Moose.
63***
64
65EOF
66
67 $found = 1;
68 }
69 }
70
7aaa2004 71 return unless $found;
72
0161e7d4 73 # More or less copied from Module::Build
74 return if $ENV{PERL_MM_USE_DEFAULT};
75 return unless -t STDIN && (-t STDOUT || !(-f STDOUT || -c STDOUT));
76
7aaa2004 77 sleep 4;
0161e7d4 78}