#!/usr/bin/perl -w use strict; use CPAN; my @cpanmods = qw / Algorithm::Interval2Prefix \ Apache::Session::File \ ... other modules go here XML::Generator /; for my $cpanmod ( @cpanmods ) { for my $mod (CPAN::Shell->expand("Module", $cpanmod )) { print "http://search.cpan.org/CPAN/authors/id/" . $mod->{'RO'}{'CPAN_FILE'} . "\n"; } }