forked from karinils/supersmart-phylota
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile.PL
48 lines (44 loc) · 1.11 KB
/
Makefile.PL
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
#!/usr/bin/perl
use strict;
use warnings;
use lib 'lib';
use ExtUtils::MakeMaker;
WriteMakefile(
'NAME' => 'Bio::Phylo::PhyLoTA',
'PREREQ_PM' => {
'DBIx::Class' => 0,
'Getopt::Long' => 0,
'Pod::Usage' => 0,
'Bio::Phylo' => 0,
'Template' => 0,
'Config::Tiny' => 0,
'DBI' => 0,
'DBD::mysql' => 0,
'Moose' => 0,
'Bio::Species' => 0,
'XML::Twig' => 0,
'HTML::Parser' => 0,
'JSON' => 0,
'Parallel::MPI::Simple' => 0,
}
);
sub MY::postamble {
my %args = %{ shift(@_) };
my $result;
eval {
require Template;
require Bio::Phylo::PhyLoTA::Config;
$args{'conf'} = Bio::Phylo::PhyLoTA::Config->new('conf/phylota.ini');
my $tt = Template->new();
$tt->process('Makefile.tmpl',\%args,\$result) || die $tt->error;
};
if ( $@ ) {
warn "*** Couldn't create extended Makefile.\n",
"*** Re-run $0 after resolving missing dependencies.\n",
"*** The error message we got was:\n $@";
return undef;
}
else {
return $result;
}
}