X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=Makefile.PL;h=ebe7a504b3838c71a4574149ea3354408a1feaae;hb=c2de7be01154d2df9ede0dff3ae1136422d462fc;hp=f2871215e36016a0f3030c1ffdbb2063ea354f8d;hpb=14f66d40970bef63105be046a109c1a32859a8a0;p=perl%2Fmodules%2FVariable-Magic.git diff --git a/Makefile.PL b/Makefile.PL index f287121..ebe7a50 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -1,7 +1,26 @@ +use 5.007003; + use strict; use warnings; use ExtUtils::MakeMaker; +eval { + require Config; +}; +die "OS unsupported" if $@; + +my @DEFINES; + +my $pl = $Config::Config{perl_patchlevel}; +print "Checking perl patchlevel... "; +if (defined $pl && length $pl) { + $pl = int $pl; + push @DEFINES, DEFINE => '-DVMG_PERL_PATCHLEVEL=' . $pl; + print $pl, "\n"; +} else { + print "none\n"; +} + WriteMakefile( NAME => 'Variable::Magic', AUTHOR => 'Vincent Pit ', @@ -9,6 +28,7 @@ WriteMakefile( VERSION_FROM => 'lib/Variable/Magic.pm', ABSTRACT_FROM => 'lib/Variable/Magic.pm', PL_FILES => {}, + @DEFINES, PREREQ_PM => { 'Carp' => 0, 'Exporter' => 0,