Search code examples
perlcpan

What are your tricks for speeding up CPAN on limited resource devices?


I was recently trying to upgrade a few Perl modules on my cell phone (nokia n900), and installing the latest copy of Module::Build for an hour.

Most of the time (70%) seemed to be spent parsing and indexing the repository information.

It seems there are a few options, such as not rebuilding the index cache each time, or using CPAN::SQLite.

I would like to continue using CPAN on the device, rather than installing the modules manually. So I am wondering what techniques people have had success with on similar limited resource devices (slowish cpu, limited ram, slow disk (flash))?


Solution

  • I believe this was one of the primary reasons why Miyagawa created cpanminus.

    From the POD:

    Another CPAN installer?

    OK, the first motivation was this: the CPAN shell runs out of memory (or swaps heavily and gets really slow) on Slicehost/linode's most affordable plan with only 256MB RAM. Should I pay more to install perl modules from CPAN? I don't think so.

    I've not used cpanm on a limited resource device/machine but I have been using it exclusively on my Perl 5.12 dev and its been a dream!

    /I3az/