Perl Module Location: Difference between revisions
From Leo's Notes
This page was last edited on 1 September 2019, at 06:22.
m Text replacement - "{{highlight|lang=bash" to "{{highlight|lang=terminal" |
m Text replacement - "Category:Linux{{Navbox Linux}}" to "{{Navbox Linux}}Category:Linux" |
||
| (One intermediate revision by the same user not shown) | |||
| Line 20: | Line 20: | ||
[[Category:Code]] | [[Category:Code]] | ||
[[Category:Linux]] | {{Navbox Linux}}[[Category:Linux]] | ||
Latest revision as of 06:22, 1 September 2019
To find a perl module's location, run
perl -M$ModuleName -e'print $_ . " => " . $INC{$_} . "\n" for keys %INC'
Replace $ModuleName with the perl module name. This is case sensitive.
Eg:
# perl -Mlocal::lib -e'print $_ . " => " . $INC{$_} . "\n" for keys %INC'
warnings.pm => /usr/share/perl5/warnings.pm
local/lib.pm => /usr/local/share/perl5/local/lib.pm
strict.pm => /usr/share/perl5/strict.pm
Config.pm => /usr/lib64/perl5/Config.pm