X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=Makefile.PL;h=4a1f9459db89f754069f0c16777c8373574373a1;hb=fcfeb2180a98d41e14a848f7bb8ba0d05b297c52;hp=35d469a71ea151e0ad91d722dcd734110dad9fc6;hpb=3cadc28babc49dbbb76ef7ff7344add68f59c3c2;p=perl%2Fmodules%2FIPC-MorseSignals.git diff --git a/Makefile.PL b/Makefile.PL index 35d469a..4a1f945 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -2,6 +2,24 @@ use strict; use warnings; use ExtUtils::MakeMaker; +BEGIN { + eval { require Config }; + die "You need the Config module to install this distribution, that's what happened" if $@; + Config->import qw/%Config/; +} + +my %sigs; +@sigs{split ' ', $Config{sig_name}} = (); + +for (qw/USR1 USR2/) { + print "Checking if you have SIG$_... "; + unless (exists $sigs{$_}) { + print "no\n"; + die "Installation stops right here,"; + } + print "yes\n"; +} + WriteMakefile( NAME => 'IPC::MorseSignals', AUTHOR => 'Vincent Pit ', @@ -10,9 +28,11 @@ WriteMakefile( ABSTRACT_FROM => 'lib/IPC/MorseSignals.pm', PL_FILES => {}, PREREQ_PM => { + 'Carp' => 0, 'POSIX' => 0, 'Test::More' => 0, 'Time::HiRes' => 0, + 'utf8' => 0, }, dist => { PREOP => 'pod2text lib/IPC/MorseSignals.pm > $(DISTVNAME)/README',