X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=Makefile.PL;h=2148282188fc918f256319c390ced2db7e9689ba;hb=6ddf6c8f21e793558d46727a4882b456f2c67c87;hp=fb5305f1a912348d9bd673a972c89a269ee9fea3;hpb=e2a962e18f036655d9e9e302a9b402754bc873c4;p=catagits%2FCatalyst-Devel.git diff --git a/Makefile.PL b/Makefile.PL index fb5305f..2148282 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -1,16 +1,111 @@ -use inc::Module::Install 0.62; +use strict; +use warnings; +use inc::Module::Install 0.91; +use Module::Install::AuthorRequires; -perl_version '5.8.1'; +name 'Catalyst-Devel'; +all_from 'lib/Catalyst/Devel.pm'; -name 'Catalyst::Helper'; -all_from 'lib/Catalyst/Helper.pm'; - -requires 'perl' => '5.8.1'; -requires 'Class::Accessor::Fast'; +requires 'Moose'; +requires 'MooseX::Emulate::Class::Accessor::Fast'; +requires 'File::ShareDir'; +requires 'namespace::clean'; +requires 'namespace::autoclean'; +requires 'Catalyst' => '5.80015'; +requires 'Catalyst::Action::RenderView' => '0.10'; +requires 'Catalyst::Plugin::Static::Simple' => '0.28'; +requires 'Catalyst::Plugin::ConfigLoader' => '0.30'; +requires 'Config::General' => '2.42'; # as of 1.07, we use .conf and not .yaml +requires 'File::ChangeNotify' => '0.07'; +requires 'File::Copy::Recursive'; requires 'Path::Class' => '0.09'; requires 'Template' => '2.14'; -requires 'Catalyst' => '5.66'; -requires 'Catalyst::Plugin::Static::Simple'; -requires 'Catalyst::Plugin::ConfigLoader'; + +# The Catalyst applications this module distribution have a Makefile.PL using +# Module::Install as well as the Module::Install::Catalyst extension included in +# this distribution. Therefore we really *depend* on Module::Install to be +# installed, even though we also use it to build this distribution and include +# it in its inc/ directory for releases. +requires 'Module::Install' => '0.91'; + +author_requires 'IPC::Run3'; +author_requires 'Module::Info'; +author_requires 'File::Find::Rule'; + +test_requires 'Test::More' => '0.94'; + +install_share 'share'; + +if ( $^O eq 'MSWin32' ) { + # Proc::Background needs this on Win32 but doesn't actually + # require it, if it's missing it just dies in the Makefile.PL. + requires 'Win32::Process' => '0.04'; + requires 'Proc::Background'; +} + +if (!$ENV{CATALYST_DEVEL_NO_510_CHECK}) { + use Symbol 'gensym'; + use IPC::Open3; + use File::Spec; + open NULL, '>', File::Spec->devnull; + my $err = gensym; + my $pid = open3(gensym, '&>NULL', $err, "$^X -It/lib -MUnknownError -e 1"); + + my $unknown_error = 0; + + while (<$err>) { + $unknown_error = 1 if /^Unknown error/; + } + + waitpid $pid, 0; + + if ($unknown_error) { + warn <= 5.009_005 && can_use('Class::C3') && !can_use('Class::C3', 0.20)) { + requires 'Class::C3' => '0.20'; +} + +auto_install; WriteAll; + +if ($Module::Install::AUTHOR) { + Meta->{values}{resources} = [ + [ 'MailingList' => 'http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst' ], + [ 'IRC' => 'irc://irc.perl.org/#catalyst' ], + [ 'license', => 'http://dev.perl.org/licenses/' ], + [ 'homepage', => 'http://dev.catalyst.perl.org/'], + [ 'repository', => 'git://git.shadowcat.co.uk/catagits/Catalyst-Devel.git' ], + ]; + + Meta->{values}{requires} = [ grep { + $_->[0] ne 'Class::C3' + } @{ Meta->{values}{requires} } ]; + + Meta->write; +}