Commit | Line | Data |
693e890f |
1 | use inc::Module::Install 0.91; |
54616d61 |
2 | |
3 | name 'Catalyst-Devel'; |
c93c671b |
4 | all_from 'lib/Catalyst/Devel.pm'; |
68ccb5e5 |
5 | |
ee99bea5 |
6 | requires 'Moose'; |
5561a11e |
7 | requires 'File::ShareDir'; |
4753780f |
8 | requires 'namespace::clean'; |
cf042872 |
9 | requires 'namespace::autoclean'; |
15f460a5 |
10 | requires 'Catalyst' => '5.8001402'; |
a2301033 |
11 | requires 'Catalyst::Action::RenderView' => '0.10'; |
12 | requires 'Catalyst::Plugin::Static::Simple' => '0.21'; |
13 | requires 'Catalyst::Plugin::ConfigLoader' => '0.23'; |
fa60b7ee |
14 | requires 'Config::General' => '2.42'; # as of 1.07, we use .conf and not .yaml |
396a43ae |
15 | requires 'File::ChangeNotify' => '0.07'; |
fde6650e |
16 | requires 'File::Copy::Recursive'; |
693e890f |
17 | requires 'Module::Install' => '0.91'; |
3d63fa09 |
18 | requires 'Path::Class' => '0.09'; |
19 | requires 'Template' => '2.14'; |
54616d61 |
20 | |
91497b69 |
21 | test_requires 'Test::More' => '0.90'; |
22 | |
afd739f1 |
23 | install_share 'share'; |
24 | |
2e9609df |
25 | if ( $^O eq 'MSWin32' ) { |
62cb5aed |
26 | # Proc::Background needs this on Win32 but doesn't actually |
2e9609df |
27 | # require it, if it's missing it just dies in the Makefile.PL. |
28 | requires 'Win32::Process' => '0.04'; |
29 | requires 'Proc::Background'; |
30 | } |
31 | |
1cbc4fbe |
32 | if (!$ENV{CATALYST_DEVEL_NO_510_CHECK}) { |
33 | use Symbol 'gensym'; |
34 | use IPC::Open3; |
35 | use File::Spec; |
36 | open NULL, '>', File::Spec->devnull; |
37 | my $err = gensym; |
38 | my $pid = open3(gensym, '&>NULL', $err, "$^X -It/lib -MUnknownError -e 1"); |
ee99bea5 |
39 | |
1cbc4fbe |
40 | my $unknown_error = 0; |
41 | |
42 | while (<$err>) { |
43 | $unknown_error = 1 if /^Unknown error/; |
44 | } |
45 | |
46 | waitpid $pid, 0; |
47 | |
48 | if ($unknown_error) { |
49 | warn <<EOE; |
50 | ############################### WARNING ################################# |
51 | # # |
52 | # You are using perl 5.10.0 with the "Unknown error" bug. This can make # |
ee99bea5 |
53 | # developing Catalyst applications much more painful, as it will come # |
1cbc4fbe |
54 | # up with no details every time you have a syntax error in a Controller.# |
55 | # # |
56 | # For more information see: # |
57 | # # |
58 | # * http://rt.perl.org/rt3/Public/Bug/Display.html?id=49472 # |
59 | # # |
68217a55 |
60 | # It is highly recommended that you use a different version of perl or # |
61 | # compile a patched version for Catalyst development. # |
1cbc4fbe |
62 | # # |
63 | # To skip this check, set the CATALYST_DEVEL_NO_510_CHECK environment # |
64 | # variable. # |
65 | # # |
66 | ######################################################################### |
67 | |
68 | EOE |
69 | my $ans = prompt('Do you want to continue?', 'no'); |
70 | exit 0 unless $ans =~ /^y(es)?\z/i; |
71 | } |
72 | } |
73 | |
d6c4f9a7 |
74 | # kill warning from older versions of Class::C3 |
75 | if ($] >= 5.009_005 && can_use('Class::C3') && !can_use('Class::C3', 0.20)) { |
76 | requires 'Class::C3' => '0.20'; |
77 | } |
78 | |
5539814d |
79 | auto_install; |
80 | |
54616d61 |
81 | WriteAll; |
d6c4f9a7 |
82 | |
83 | if ($Module::Install::AUTHOR) { |
84 | Meta->{values}{resources} = [ |
85 | [ 'MailingList' => 'http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst' ], |
86 | [ 'IRC' => 'irc://irc.perl.org/#catalyst' ], |
87 | [ 'license', => 'http://dev.perl.org/licenses/' ], |
88 | [ 'homepage', => 'http://dev.catalyst.perl.org/'], |
89 | [ 'repository', => 'http://dev.catalyst.perl.org/repos/Catalyst/Catalyst-Devel/' ], |
90 | ]; |
91 | |
92 | Meta->{values}{requires} = [ grep { |
93 | $_->[0] ne 'Class::C3' |
94 | } @{ Meta->{values}{requires} } ]; |
95 | |
96 | Meta->write; |
97 | } |