3 # Copyright PROCURA B.V. (c) 2008-2008 H.Merijn Brand
5 require 5.006; # <- also see postamble at the bottom for META.yml
8 use ExtUtils
::MakeMaker
;
12 ABSTRACT
=> "Extended/Modified debugging utilities",
13 AUTHOR
=> "H.Merijn Brand <h.merijn\@xs4all.nl>",
14 VERSION_FROM
=> "Peek.pm",
15 PREREQ_PM
=> { "DynaLoader" => 0,
20 clean
=> { FILES
=> join " ", qw(
30 $ExtUtils::MakeMaker
::VERSION
> 6.30 and $wm{LICENSE
} = "perl";
32 unless (exists $ENV{AUTOMATED_TESTING
} and $ENV{AUTOMATED_TESTING
} == 1) {
33 if (prompt
("Do you want to install module DP as a shortcut for Data::Peek ?", "y") =~ m/[yY]/) {
35 open my $pm, "<", "Peek.pm" or die "CAnnot read Peek.pm: $!\n";
36 my $vsn = do { <$pm> =~ m/^\$VERSION\s*=\s*"([0-9._]+)/m; $1 };
39 (my $dp = <DATA
>) =~ s/::VERSION::/"$vsn"/;
40 open my $fh, ">", "DP.pm" or die "Cannot open DP.pm: $!\n";
44 "Peek.pm" => '$(INST_LIB)/Data/Peek.pm',
45 "DP.pm" => '$(INST_LIB)/DP.pm',
47 $wm{clean
}{FILES
} .= " DP.pm";
51 $ENV{NO_SV_PEEK
} and $wm{DEFINE
} = "-DNO_SV_PEEK";
53 my $rv = WriteMakefile
(%wm);
61 my $valgrind = join " ", qw(
62 PERL_DESTRUCT_LEVEL=2 PERL_DL_NONLAZY=1
64 --suppressions=sandbox/perl.supp
66 --leak-resolution=high
70 $(FULLPERLRUN) "-MExtUtils::Command::MM" "-e"
71 "test_harness($(TEST_VERBOSE), '$(INST_LIB)', '$(INST_ARCHLIB)')"
72 $(TEST_FILES
) 3>valgrind
.log
75 my $min_vsn = ($] >= 5.010 && -d
"xt" && ($ENV{AUTOMATED_TESTING
} || 0) != 1)
78 ' -@env TEST_FILES="xt/*.t" make -e test_dynamic',
88 ' -@tail -5 valgrind.log',
91 q{ sandbox/leaktest $(FULLPERLRUN) "test_harness($(TEST_VERBOSE), '$(INST_LIB)', '$(INST_ARCHLIB)')" $(TEST_FILES)},
94 ' perl sandbox/genMETA.pl -c',
97 ' perl sandbox/genMETA.pl',
99 'tgzdist: checkmeta fixmeta $(DISTVNAME).tar.gz distcheck',
100 ' -@mv -f $(DISTVNAME).tar.gz $(DISTVNAME).tgz',
101 ' -@cpants_lint.pl $(DISTVNAME).tgz',
102 ' -@rm -f Debian_CPANTS.txt',
110 BEGIN { *DP
:: = \
%Data::Peek
:: }
111 $VERSION = ::VERSION
::;
117 DP - Alias for Data::Peek
121 perl -MDP -wle'print DPeek for DDual ($?, 1)'
129 H.Merijn Brand <h.m.brand@xs4all.nl>
131 =head1 COPYRIGHT AND LICENSE
133 Copyright (C) 2008-2008 H.Merijn Brand
135 This library is free software; you can redistribute it and/or modify it
136 under the same terms as Perl itself.