Login
Delete META.yml, MANIFEST, and README. Just have them
[gknop/Perl-Critic.git] / Build.PL
CommitLineData
02b7b45d
JRT
1#######################################################################
2# $URL$
3# $Date$
4# $Author$
5# $Revision$
6########################################################################
7
9f0edba9 8BEGIN {
0d512192 9 use 5.006001;
9f0edba9
ES
10}
11
59b05e08
JRT
12use strict;
13use warnings;
34cc6052
ES
14
15use lib 'inc';
496afbe0 16use lib 't/tlib';
34cc6052 17
59b05e08
JRT
18use Module::Build;
19
70f3f307
ES
20use Perl::Critic::BuildUtilities qw<
21 recommended_module_versions
22 test_wrappers_to_generate
496afbe0 23 get_PL_files
70f3f307 24 dump_unlisted_or_optional_module_versions
7963ad6d 25 emit_tar_warning_if_necessary
70f3f307 26>;
34cc6052 27
7963ad6d 28emit_tar_warning_if_necessary();
d1a97a75 29
0d512192
ES
30
31my $class = Module::Build->subclass( code => <<'END_SUBCLASS' );
32
aae3164b
ES
33 sub ACTION_test {
34 my ($self) = @_;
35
36 $self->depends_on('manifest');
37
38 return $self->SUPER::ACTION_test();
39 } # end ACTION_distdir
40
0d512192
ES
41 sub ACTION_authortest {
42 my ($self) = @_;
43
44 $self->depends_on('build');
45 $self->depends_on('manifest');
46 $self->depends_on('distmeta');
47
48 $self->test_files( qw< t xt/author > );
49 $self->recursive_test_files(1);
50
51 $self->depends_on('test');
52
53 return;
54 } # end ACTION_authortest()
55
56 sub ACTION_distdir {
57 my ($self) = @_;
58
59 $self->depends_on('authortest');
60
aae3164b 61 return $self->SUPER::ACTION_distdir();
0d512192
ES
62 } # end ACTION_distdir
63
64END_SUBCLASS
65
66my $builder = $class->new(
5a4b3810
ES
67 module_name => 'Perl::Critic',
68 dist_author => 'Jeffrey Thalhammer <thaljef@cpan.org>',
69 dist_abstract => 'Critique Perl source code for best-practices.',
70 license => 'perl',
aae3164b
ES
71 dynamic_config => 1,
72 create_readme => 1,
73 create_packlist => 1,
74 sign => 0,
5a4b3810
ES
75
76 requires => {
77 'B::Keywords' => 1.05,
78 'Carp' => 0,
79 'Config::Tiny' => 2,
80 'English' => 0,
81 'Exception::Class' => 1.23,
82 'File::Basename' => 0,
83 'File::Find' => 0,
84 'File::Path' => 0,
85 'File::Spec' => 0,
86 'File::Spec::Unix' => 0,
87 'File::Temp' => 0,
88 'Getopt::Long' => 0,
89 'IO::String' => 0,
90 'List::MoreUtils' => 0,
91 'List::Util' => 0,
92 'Module::Pluggable' => 3.1,
5ee81b1b
ES
93 'PPI' => 1.203,
94 'PPI::Document' => 1.203,
95 'PPI::Document::File' => 1.203,
96 'PPI::Node' => 1.203,
97 'PPI::Token::Quote::Single' => 1.203,
98 'PPI::Token::Whitespace' => 1.203,
5a4b3810
ES
99 'Pod::PlainText' => 0,
100 'Pod::Select' => 0,
101 'Pod::Usage' => 0,
102 'Readonly' => 1.03,
103 'Scalar::Util' => 0,
104 'String::Format' => 1.13,
105 'base' => 0,
106 'charnames' => 0,
107 'overload' => 0,
108 'strict' => 0,
109 'version' => 0,
110 'warnings' => 0,
111 'overload' => 0,
112 'strict' => 0,
113 'version' => 0,
114 'warnings' => 0,
3fff51e5
ES
115 },
116
5a4b3810 117 recommends => { recommended_module_versions() },
3fff51e5 118
5a4b3810
ES
119 build_requires => {
120 'lib' => 0,
121 'Test::More' => 0,
3fff51e5
ES
122 },
123
5a4b3810 124 PL_files => get_PL_files(),
3fff51e5 125
5a4b3810 126 script_files => ['bin/perlcritic'],
3fff51e5 127
5a4b3810 128 meta_merge => {
8cdd9cf7
ES
129 resources => {
130 homepage => 'http://perlcritic.com',
131 license => 'http://dev.perl.org/licenses/',
c575d304 132 Repository => 'http://perlcritic.tigris.org/svn/perlcritic/trunk/Perl-Critic/',
8cdd9cf7
ES
133 MailingList => 'http://perlcritic.tigris.org/servlets/SummarizeList?listName=users',
134 }
135 },
136
3fff51e5
ES
137 add_to_cleanup => [
138 qw<
aae3164b 139 lib/Perl/Critic/PolicySummary.pod
3fff51e5
ES
140 Makefile
141 Makefile.old
aae3164b
ES
142 MANIFEST
143 MANIFEST.bak
144 META.yml
3fff51e5 145 pm_to_blib
aae3164b 146 README
3fff51e5 147 t/ControlStructures/ProhibitNegativeExpressionsInUnlessAndUntilConditions.run
47e04892 148 t/Variables/RequireLocalizedPunctuationVars.run
3fff51e5
ES
149 >,
150 test_wrappers_to_generate(),
151 ],
59b05e08
JRT
152);
153
154$builder->create_build_script();
c28a9e24 155
70f3f307
ES
156dump_unlisted_or_optional_module_versions();
157
c28a9e24
JRT
158##############################################################################
159# Local Variables:
160# mode: cperl
161# cperl-indent-level: 4
162# fill-column: 78
163# indent-tabs-mode: nil
164# c-indentation-style: bsd
165# End:
96fed375 166# ex: set ts=8 sts=4 sw=4 tw=78 ft=perl expandtab shiftround :