[Bioperl-l] using %packages in Makefile.PL

Sendu Bala bix at sendu.me.uk
Tue Sep 26 19:06:33 EDT 2006


Nathan S. Haigh wrote:
> My brains dead and it's too late for me to think.... :o)
> 
> PREREQ_PM in Makefile.PL takes a hash reference where the key is the
> module name and the value is the minimum version required, or zero if no
> minimum is required. How can I use %packages to provide this?
> 
> ugh, this should be easy but my head hurts! :o(

There's lots of ways to do it, but a simple, explicit, easy to follow way:

my %prereq;
while (my ($key, $value) = each %packages) {
   my ($version) = split("/", $value);
   $prereq{$key} = $version;
}

...
PREREQ_PM => \%prereq;


> p.s. should commits to Makefile.PL be made on the 1.5.2 branch? and will
> these changes then be merged to HEAD when the 1.5.2 release is final?

Make them to HEAD and I'll merge them to the branch.



More information about the Bioperl-l mailing list