From: "Greg London" <[email protected]>
   Date: Fri, 16 Jan 2009 12:33:17 -0800

   Is there a way to figure out a list of all the perl modules installed
   on a computer?  Regardless of where they may be installed? I don't
   want the modules that come with perl, but if the guy installed a cpan
   module in a directory with a bunch of modules that came installed
   with perl, I just want the cpan module.

   And if he put it in a weird directory, I'd need to find those too.

For that, I think your only hope is

        find / -name '*.pm'

and filter out installed directories.

   Or is it just a matter of going through @INC . . .

Anything in the built-in @INC (other than ".") will be under
/usr/lib/perl5/, and therefore not "weird".

   and hoping anything installed isn't getting used through a PERLLIB
   environment variable?

Bear in mind that this hypothetical guy you mention may also have added

        use lib 'anywhere';

to his scripts.

   Are you trying to make a particular set of scripts run on a new
computer, but don't know where said guy buried the modules it needs?  If
so, I would try running the scripts and dumping %INC at the end, to find
out which modules, and where they came from.

   HTH,

                                        -- Bob Rogers
                                           http://www.rgrjr.com/

_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm

Reply via email to