Hello,
I would like to show a message for users to install the needed perl modules when my script starts and dependencies are missing.
I would like to show users the command to install modules from the OS distribution packages first, if they are available there, and show a `cpanm` install command for modules that are not provided in OS repositories.
However, installing OS distribution packages is different for every operating system. On Ubuntu Linux for example I need to invoke `dpkg-query --list` to see if a package like libModule-Name-perl is available in the repos.
This can get complicated when I need to install one module from CPAN, but some of the dependencies are available as OS packages, in which case I should install those first.
So is there a module that can help me install a package from OS distro if available, or from CPAN otherwise ?
Also, do I understand correctly that it is recommended to prefer the CPAN modules instead of the OS ones ? I find this to be a real problem for any non-pure perl module, I belive the OS distro should be preferred in this case.
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |