1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93
|
# $Id: Makefile.PL 84 2020-05-31 06:29:34Z stro $
use strict;
use warnings;
use ExtUtils::MakeMaker;
my %broken_smokers_roots = map { $_ => 1 } (
'/home/opc/perl5/perlbrew',
'/home/njh/perl5/perlbrew',
);
if ($ENV{'PERLBREW_ROOT'} && $broken_smokers_roots{ $ENV{'PERLBREW_ROOT'} }) {
my $honest_answer = ExtUtils::MakeMaker::prompt('This smoker setup is most definitely broken and the author is tired of FP. Please type "Yes. I swear I fixed it. Please continue." to continue: ');
unless ($honest_answer and $honest_answer eq 'Yes. I swear I fixed it. Please continue.') {
print 'Kthxbye', $/;
exit 0;
}
}
my @exe_files = map {"bin/$_"} qw(cpandb);
my $goners = join ' ', qw(
cpandb.sql
t/dot-cpan/cpandb.sql
t/dot-cpan/FTPstats.yml
t/dot-cpan/CPAN/MyConfig.pm
t/dot-cpan/cpan_sqlite_log.*
t/dot-cpan/sources/authors/01mailrc.txt.gz
t/dot-cpan/sources/modules/02packages.details.txt.gz
t/dot-cpan/sources/modules/03modlist.data.gz
t/cpan-t-06/*
t/cpan-t-07/*
t/cpan-t-08/*
);
my %opts = (
'NAME' => 'CPAN::SQLite',
'VERSION_FROM' => 'lib/CPAN/SQLite.pm',
'EXE_FILES' => \@exe_files,
'PL_FILES' => {},
'dist' => {
'SUFFIX' => 'gz',
'COMPRESS' => 'gzip -9f',
},
'clean' => {
'FILES' => $goners
},
);
my $eu_version = $ExtUtils::MakeMaker::VERSION;
$eu_version =~ s/_//msgx;
if ($eu_version >= 5.43) {
%opts = (%opts,
'ABSTRACT_FROM' => 'lib/CPAN/SQLite.pm',
'AUTHOR' => 'Serguei Trouchelle <stro@cpan.org>',
);
}
my $prereqs = {
'File::Spec' => 0,
'Archive::Tar' => 1.54,
'IO::Zlib' => 0,
'Compress::Zlib' => 0,
'CPAN::DistnameInfo' => 0.09,
'DBD::SQLite' => 1.27, # for REGEXP implementation
'File::HomeDir' => 0,
'HTTP::Tiny' => 0.041,
'CPAN::Index' => 1.93, # No more false negatives because of CPAN-Index
'parent' => 0,
};
my $test_prereqs = {
};
if ($ENV{'HARNESS_OPTIONS'}) {
# Parallel testing requires Test::Harness 3.31
$prereqs->{'Test::Harness'} = 3.31;
}
if ($eu_version >= '6.64') {
%opts = (%opts,
'PREREQ_PM' => $prereqs,
'TEST_REQUIRES' => $test_prereqs,
);
} else {
%opts = (%opts,
'PREREQ_PM' => { %{$prereqs}, %{$test_prereqs} },
);
}
WriteMakefile( %opts );
|