to check which perl stuff (modules) is running on my opensus

Einfach Dinge, die nichts mit XAMPP, Apache Friends, Apache, MySQL, PHP und alle dem zu tun haben. Allerlei halt. ;)

to check which perl stuff (modules) is running on my opensus

Postby unleash » 22. June 2013 16:16

how to check which perl stuff (modules) is running on my opensuse 12.3

well you see this is not a puppy question - but i am currently plannning stage of my first puppy-things. i want to create a puppy dvd with perl modules.

but first of all - i need to know what ( wich) perl stuff is on my machine!?


can you help out?

update:


hmmm this is abit crazy isn t it?

i runned this

Code: Select all
perl -e 'print "rpm -qf  $_\n" foreach @INC'|/bin/sh|sort -u   


results:

Code: Select all
o conf commit
martin@linux-wyee:~/php>   firefox -repl
martin@linux-wyee:~/php> perl -e 'print "rpm -qf  $_\n" foreach @INC'|/bin/sh|sort -u
file /home/martin/php is not owned by any package
perl-5.16.0-3.5.1.i586
perl-base-5.16.0-3.5.1.i586
perl-B-Utils-0.21-2.1.2.i586
perl-Class-C3-XS-0.13-12.1.2.i586
perl-Class-Load-XS-0.04-4.1.2.i586
perl-Data-Dump-Streamer-2.33-2.1.2.i586
perl-Devel-GlobalDestruction-0.04-3.1.1.i586
perl-Digest-MD4-1.5-154.1.2.i586
perl-Digest-SHA1-2.13-11.1.2.i586
perl-gettext-1.05-157.1.2.i586
perl-HTML-Parser-3.69-12.1.2.i586
perl-HTTP-Server-Simple-0.44-2.1.1.i586
perl-List-MoreUtils-0.33-2.1.2.i586
perl-Moose-2.0602-2.1.2.i586
perl-Net-DBus-1.0.0-3.1.2.i586
perl-Net-LibIDN-0.12-9.1.2.i586
perl-Net-SSLeay-1.42-3.1.2.i586
perl-Package-Stash-XS-0.25-4.1.2.i586
perl-PadWalker-1.92-12.1.2.i586
perl-Params-Util-1.07-2.1.2.i586
perl-Sub-Name-0.05-21.1.2.i586
perl-Task-Weaken-1.04-14.1.1.i586
perl-Test-Exception-0.31-13.1.1.i586
perl-Text-CSV_XS-0.87-2.1.2.i586
perl-Unicode-Map-0.112-6.1.2.i586
perl-Variable-Magic-0.48-2.1.2.i586
perl-X11-Protocol-0.56-7.1.1.i586
perl-XML-LibXML-1.95-4.1.2.i586
perl-XML-NamespaceSupport-1.11-15.1.1.i586
perl-XML-Parser-2.41-15.1.2.i586
martin@linux-wyee:~/php>   


ONE QUESTION LEFT: does this show all (!!!) the perl-module-stuff on the whole machine!?

ps this board is top notch i love it. keep it up!!

greetings so much!! i find answers which i normally do not find. and i must confess that i love this site !!

greetings
unleash
 
Posts: 141
Joined: 03. December 2011 10:16
Operating System: OpenSuse Linux 12.1

Re: to check which perl stuff (modules) is running on my ope

Postby unleash » 22. June 2013 21:39

hi there - found some pretty useful ideas


http://stackoverflow.com/questions/1154 ... an-modules


well - it is pretty useful to run this one command:

one can use the CPAN 'r' command for this. You can get into the CPAN shell with the old style:

sudo perl -MCPAN -e shell

or, on most newer systems, there is a 'cpan' command, so this command will get you to the shell


or another way is to go this way:



and a just very very hacky way to do it in *nix world,
you'll get some stuff you don't really care about (ie: warnings::register etc),
but it should give you a list of every .pm file that's accessible via perl.

Code: Select all
for my $path (@INC) {
    my @list = `ls -R $path/**/*.pm`;
    for (@list) {
        s/$path\///g;
        s/\//::/g;
        s/\.pm$//g;
        print;
    }
}



just another way is to do it like this - see here the cpan-module: http://search.cpan.org/dist/App-Module- ... /Lister.pm

another way: it is descriped here: App::Module::ListerI - search.cpan.org
the App::Module::ListerI - List the Perl modules in @INC


the question: well can i run this in a NON -SERVER ENVIRONMENT!? TOO!?

i want to use it on my notebook


App::Module::ListerI - search.cpan.org

Code: Select all
    PHP Code:
    cpan[6]>  install  App::Module::Lister
    Running install for module 'App::Module::Lister'
    Running make for B/BD/BDFOY/App-Module-Lister-0.13.tar.gz
    Fetching with LWP:
    http://cpan.mirror.anlx.net/authors/id/B/BD/BDFOY/App-Module-Lister-0.13.tar.gz
    Fetching with LWP:
    http://cpan.mirror.anlx.net/authors/id/B/BD/BDFOY/CHECKSUMS
    Checksum for /home/martin/.cpan/sources/authors/id/B/BD/BDFOY/App-Module-Lister-0.13.tar.gz ok
    Scanning cache /home/martin/.cpan/build for sizes
    ............................................................................DONE

      CPAN.pm: Building B/BD/BDFOY/App-Module-Lister-0.13.tar.gz

    Checking if your kit is complete...
    Looks good
    Writing Makefile for App::Module::Lister
    Writing MYMETA.yml and MYMETA.json
    cp lib/Lister.pm blib/lib/App/Module/Lister.pm
    Manifying blib/man3/App::Module::Lister.3
      BDFOY/App-Module-Lister-0.13.tar.gz
      /usr/bin/make -- OK
    Running make test
    PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
    t/load.t .......... ok   
    t/pod.t ........... ok   
    t/pod_coverage.t .. ok   
    All tests successful.
    Files=3, Tests=3,  0 wallclock secs ( 0.04 usr  0.00 sys +  0.19 cusr  0.01 csys =  0.24 CPU)
    Result: PASS
      BDFOY/App-Module-Lister-0.13.tar.gz
      /usr/bin/make test -- OK
    Running make install
    root's password:
    Installing /usr/lib/perl5/site_perl/5.16.0/App/Module/Lister.pm
    Installing /usr/share/man/man3/App::Module::Lister.3
    Appending installation info to /usr/lib/perl5/5.16.0/i586-linux-thread-multi/perllocal.pod
      BDFOY/App-Module-Lister-0.13.tar.gz
      sudo /usr/bin/make install  -- OK

    cpan[7]>




i try to run this on my lappy...
unleash
 
Posts: 141
Joined: 03. December 2011 10:16
Operating System: OpenSuse Linux 12.1


Return to Allerlei

Who is online

Users browsing this forum: No registered users and 2 guests