5 use ExtUtils::MakeMaker;
8 eval { require Config };
9 die 'OS unsupported' if $@;
10 Config->import(qw/%Config/);
15 my $pl = $Config{perl_patchlevel};
16 print "Checking perl patchlevel... ";
17 if (defined $pl && length $pl) {
19 push @DEFINES, '-DVMG_PERL_PATCHLEVEL=' . $pl;
26 print "Checking if this is ActiveState Perl 5.8.8 build 822 or higher... ";
32 if (defined &ActivePerl::BUILD) {
33 my $build = int ActivePerl::BUILD();
36 push @DEFINES, '-DVMG_COMPAT_ARRAY_PUSH_NOLEN=1';
41 print $is_as ? "yes\n" : "no\n";
43 # Threads, Windows and 5.8.x don't seem to be best friends
44 if ($^O eq 'MSWin32' && $^V lt v5.9.0) {
45 push @DEFINES, '-DVMG_MULTIPLICITY=0';
48 # Fork emulation got "fixed" in 5.10.1
49 if ($^O eq 'MSWin32' && $^V lt v5.10.1) {
50 push @DEFINES, '-DVMG_FORKSAFE=0';
53 @DEFINES = (DEFINE => join ' ', @DEFINES) if @DEFINES;
55 my $dist = 'Variable-Magic';
58 configure_requires => {
60 'ExtUtils::MakeMaker' => 0,
65 'ExtUtils::MakeMaker' => 0,
69 bugtracker => "http://rt.cpan.org/NoAuth/ReportBug.html?Queue=$dist",
70 homepage => "http://search.cpan.org/dist/$dist/",
71 license => 'http://dev.perl.org/licenses/',
72 repository => "http://git.profvince.com/?p=perl%2Fmodules%2F$dist.git",
77 NAME => 'Variable::Magic',
78 AUTHOR => 'Vincent Pit <perl@profvince.com>',
80 VERSION_FROM => 'lib/Variable/Magic.pm',
81 ABSTRACT_FROM => 'lib/Variable/Magic.pm',
90 MIN_PERL_VERSION => 5.008,
93 PREOP => 'pod2text lib/Variable/Magic.pm > $(DISTVNAME)/README',
94 COMPRESS => 'gzip -9f', SUFFIX => 'gz'
97 FILES => "$dist-* *.gcov *.gcda *.gcno cover_db Debian_CPANTS.txt"