3 # Copyright PROCURA B.V. (c) 2008-2013 H.Merijn Brand
5 require 5.008; # <- also see postamble at the bottom for META.yml
8 use ExtUtils
::MakeMaker
;
12 DISTNAME
=> "Data-Peek",
13 ABSTRACT
=> "Extended/Modified debugging utilities",
14 AUTHOR
=> "H.Merijn Brand <h.merijn\@xs4all.nl>",
15 VERSION_FROM
=> "Peek.pm",
16 PREREQ_PM
=> { "DynaLoader" => 0,
20 "Test::NoWarnings" => 0,
22 clean
=> { FILES
=> join " ", qw(
31 macro
=> { TARFLAGS
=> "--format=ustar -c -v -f",
34 $ExtUtils::MakeMaker
::VERSION
> 6.30 and $wm{LICENSE
} = "perl";
36 unless (exists $ENV{AUTOMATED_TESTING
} and $ENV{AUTOMATED_TESTING
} == 1) {
37 if (prompt
("Do you want to install module DP as a shortcut for Data::Peek ?", "y") =~ m/[yY]/) {
39 open my $pm, "<", "Peek.pm" or die "CAnnot read Peek.pm: $!\n";
40 my $vsn = do { <$pm> =~ m/^\$VERSION\s*=\s*"([0-9._]+)/m; $1 };
43 (my $dp = <DATA
>) =~ s/::VERSION::/"$vsn"/;
44 open my $fh, ">", "DP.pm" or die "Cannot open DP.pm: $!\n";
48 "Peek.pm" => '$(INST_LIB)/Data/Peek.pm',
49 "DP.pm" => '$(INST_LIB)/DP.pm',
51 $wm{clean
}{FILES
} .= " DP.pm";
55 $ENV{NO_SV_PEEK
} and $wm{DEFINE
} = "-DNO_SV_PEEK";
57 my $rv = WriteMakefile
(%wm);
65 my $valgrind = join " ", qw(
66 PERL_DESTRUCT_LEVEL=2 PERL_DL_NONLAZY=1
68 --suppressions=sandbox/perl.supp
70 --leak-resolution=high
74 $(FULLPERLRUN) "-MExtUtils::Command::MM" "-e"
75 "test_harness($(TEST_VERBOSE), '$(INST_LIB)', '$(INST_ARCHLIB)')"
76 $(TEST_FILES
) 3>valgrind
.log
79 my $min_vsn = ($] >= 5.010 && -d
"xt" && ($ENV{AUTOMATED_TESTING
} || 0) != 1)
82 ' -@env TEST_FILES="xt/*.t" make -e test_dynamic',
92 ' -@tail -5 valgrind.log',
95 q{ sandbox/leaktest $(FULLPERLRUN) "test_harness($(TEST_VERBOSE), '$(INST_LIB)', '$(INST_ARCHLIB)')" $(TEST_FILES)},
98 ' pod-spell-check --aspell --ispell',
100 'checkmeta: spellcheck',
101 ' perl sandbox/genMETA.pl -c',
104 ' perl sandbox/genMETA.pl',
106 'tgzdist: checkmeta fixmeta $(DISTVNAME).tar.gz distcheck',
107 ' -@mv -f $(DISTVNAME).tar.gz $(DISTVNAME).tgz',
108 ' -@cpants_lint.pl $(DISTVNAME).tgz',
109 ' -@rm -f Debian_CPANTS.txt',
117 BEGIN { *DP
:: = \
%Data::Peek
:: }
118 $VERSION = ::VERSION
::;
124 DP - Alias for Data::Peek
128 perl -MDP -wle'print DPeek for DDual ($?, 1)'
136 H.Merijn Brand <h.m.brand@xs4all.nl>
138 =head1 COPYRIGHT AND LICENSE
140 Copyright (C) 2008-2013 H.Merijn Brand
142 This library is free software; you can redistribute it and/or modify it
143 under the same terms as Perl itself.