Login
Change $VERSION to a string instead of a number to deal with
[gknop/Perl-Critic.git] / Makefile.PL
CommitLineData
02b7b45d
JRT
1#######################################################################
2# $URL$
3# $Date$
4# $Author$
5# $Revision$
345c7562 6# ex: set ts=8 sts=4 sw=4 tw=78 ft=perl expandtab :
02b7b45d
JRT
7########################################################################
8
59b05e08
JRT
9use strict;
10use warnings;
34cc6052
ES
11
12use lib 'inc';
13use lib 'lib';
14
59b05e08
JRT
15use ExtUtils::MakeMaker;
16
70f3f307
ES
17use Perl::Critic::BuildUtilities qw<
18 test_wrappers_to_generate
496afbe0 19 get_PL_files
70f3f307
ES
20 dump_unlisted_or_optional_module_versions
21>;
34cc6052 22
d1a97a75 23my $warning = <<'END_WARNING';
d06bd3e7 24
a4141f24
JRT
25###################################################
26# NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! #
27#-------------------------------------------------#
28# In this version of Perl::Critic, some of #
29# the Policy modules have been renamed to better #
30# better reflect the intent of the Policy. If #
31# you have an older version of Perl::Critic #
32# already installed, it will cause many of the #
33# tests to fail and the new version will not work #
34# properly. #
35# #
36# I strongly advise you to remove the current #
37# version of Perl::Critic before proceeding with #
38# this installation. In most cases, this can be #
39# done by deleting everything below the #
40# Perl/Critic/Policy directory in your site_perl #
41# location. #
42# #
43# Also, if you have created a .perlcriticrc file, #
44# you will need to update it to match the new #
45# Policy module names. #
46# #
47# Sorry for the inconvenience. #
48# #
49# -Jeff <thaljef@cpan.org> #
50###################################################
d06bd3e7 51
a4141f24
JRT
52END_WARNING
53
d1a97a75
JRT
54
55eval {
56 require Perl::Critic;
57 warn $warning if $Perl::Critic::VERSION < 0.14;
58};
59
60
f372073c
AL
61WriteMakefile(
62 NAME => 'Perl::Critic',
63 AUTHOR => 'Jeffrey Thalhammer <thaljef@cpan.org>',
64 ABSTRACT_FROM => 'lib/Perl/Critic.pm',
bb9f1668 65 VERSION_FROM => 'lib/Perl/Critic.pm',
f372073c 66 EXE_FILES => ['bin/perlcritic'],
496afbe0 67 PL_FILES => get_PL_files(),
f372073c 68 PREREQ_PM => {
e2d4c0f0 69 'B::Keywords' => 1.05,
f372073c
AL
70 'Config::Tiny' => 2,
71 'File::Spec' => 0,
72 'File::Spec::Unix' => 0,
73 'IO::String' => 0,
74 'List::MoreUtils' => 0,
75 'List::Util' => 0,
a7340650 76 'Module::Pluggable' => 3.1,
f372073c
AL
77 'PPI' => 1.118,
78 'Pod::PlainText' => 0,
79 'Pod::Usage' => 0,
c680a9c9 80 'Readonly' => 1.03,
f372073c 81 'Scalar::Util' => 0,
f372073c
AL
82 'String::Format' => 1.13,
83 'Test::More' => 0,
84 },
6d34b243
ES
85 realclean => {
86 FILES =>
87 join
88 q< >,
89 test_wrappers_to_generate(),
90 't/ControlStructures/ProhibitNegativeExpressionsInUnlessAndUntilConditions.run'
91 },
59b05e08 92);
e2d1c3dd
AL
93
94sub MY::postamble {
c1c3dd88 95 return <<"MAKE_FRAG";
e2d1c3dd
AL
96.PHONY: tags
97
98tags:
c1c3dd88
ES
99\tctags -f tags \\
100\t\t--recurse \\
101\t\t--totals \\
102\t\t\\
103\t\t--exclude=blib/ \\
104\t\t--exclude=t/lib \\
105\t\t--exclude=.svn \\
106\t\t--exclude='*~' \\
107\t\t\\
108\t\t--languages=Perl \\
fdac20fb 109\t\t--langmap=Perl:+.t
e2d1c3dd
AL
110MAKE_FRAG
111}
112
70f3f307
ES
113dump_unlisted_or_optional_module_versions();
114
c28a9e24
JRT
115##############################################################################
116# Local Variables:
117# mode: cperl
118# cperl-indent-level: 4
119# fill-column: 78
120# indent-tabs-mode: nil
121# c-indentation-style: bsd
122# End:
123# ex: set ts=8 sts=4 sw=4 tw=78 ft=perl expandtab :