X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=Makefile.PL;h=ebe7a504b3838c71a4574149ea3354408a1feaae;hb=9e65e9bfbd5fa2ee747e865d1471b26ec229383c;hp=f76dda4b2e08f085026b7a324d88e9d0a26d2f70;hpb=fee1a480bc5d827590dc7394e0a77741bad86dc3;p=perl%2Fmodules%2FVariable-Magic.git diff --git a/Makefile.PL b/Makefile.PL index f76dda4..ebe7a50 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -4,6 +4,23 @@ 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 ', @@ -11,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,