I just wonder - are there any advantages to installing perl modules from the cpan shell compared to installing them by package management? Apart from occasionally having quicker access to the latest modules version?
CPAN (Comprehensive Perl Archive Network) is is a repository of over 250,000 Perl modules, written by over 12,000 contributors. See CPAN Website at https://www.cpan.org for more information. CPAN Shell is Perl module that provides an shell interface to manage installations of CPAN Perl modules.
Available commands are: l - List all installed modules m - Select a module q - Quit the program cmd? Sample outputs: Installed modules are: JavaScript::SpiderMonkey Log::Log4perl Perl cmd?
Well, it all depends on the intended use of the modules.
The native package management has many advantages:
When installing directly from CPAN, you also have some advantages:
Nowadays, local::lib and perlbrew (howto) has made the CPAN way a lot more interesting for a developer. local::lib lets you have your private module tree while using the system's perl binary and perlbrew lets you easily create your own complete Perl installations (also several Perl releases in parallel).
Both ways are valid, and as said, the advantage depends on the intended usage.
Using a native CPAN client gives you access to all modules on CPAN, most of which probably aren't packaged by your distro, but at the cost of your distro's package manager not knowing that they're installed (for dependency resolution, etc.). I know that Debian provides the dh-make-perl
package for converting CPAN modules to debs, which seems like it should give you the best of both worlds, but I've never tried it myself.
The most important thing, though, is to pick one method or the other and stick with it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With