#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0

    nstalling Perl-Modules: via YAST or Terminal (cpan)


    hello dear linux-experts,


    how to do installs of Perl-modules :: which way is the best? installing Perl-Modules: via YAST or Terminal (cpan) in other words:

    a. via console or
    b. via yast


    btw: at the console i can do it like so: for an example i want to install

    Code:
    cpan> install HTML::TreeBuilder::LibXML
    i can do it like so:


    Code:
    perl -MCPAN -e shell
    on first run you'll need to configure it, just follow defaults, get local repositorie
    cpan> install HTML::TreeBuilder::LibXML
    and we should be good, or the YAST package manager may allow us to install Perl modules as well


    but sure i can do a check of the modules that i allready have installed

    note: at the beginning - i need the following

    mozrepl
    XML::Twig
    DBI
    XML::Simple
    mysql
    Perl Mechanize
    Mozrepl - addon for the Web-Browser
    www mechanize firefox

    well subsequently - i need to have a good make - (note: in the past time i often have had issues with the make)
    so i need a good make: Therefore i need to check the version of the make that currently is installed

    question: do i need to have a good Make?


    one last question: what about - does the following module help to get an overview on all the modules i have installed.

    Module::Load::Conditional - search.cpan.org

    DESCRIPTION
    Module::Load::Conditional provides simple ways to query and possibly load any of the modules you have installed on your system during runtime.It is able to load multiple modules at once or none at all if one of them was not able to load. It also takes care of any error checking and so forth.


    look forward to hear from you

    greetings
  2. #2
  3. !~ /m$/
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    May 2004
    Location
    Reno, NV
    Posts
    4,274
    Rep Power
    0
    You can install modules either with CPAN or a package manager. I won't say one is better than another.

    A package manager is great when the software you want is available, supported, and updated regularly. The only problem comes when the version available lags the most current release by quite a bit.

    And the problem with using CPAN or compiling from source is that sometimes the build settings don't work for your operating system, and you are left to figure that out by yourself. I'm sure you have seen both problems by now.

    So there is no reason to use only one method. If the module installs easily with CPAN, use it. If there is trouble installing, look for a package.

    ---

    I think Module::Load::Conditional is intended to dynamically load modules at runtime. I isn't meant to provide a list of installed modules.

    How do I find which modules are installed on my system?
    perlfaq3: How do I find which modules are installed on my system

    Comments on this post

    • metabo agrees
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    hello dear Keath

    many thanks i will do as adviced.

    you have convinced me to take a look at both sites.

    btw: had lots of issues with Mechanize::Firefox and Mozrepl
    guess that you remember these issues - i talked bout these things here.
    Now - more than year later - i hope that i can retry the installation again.
    Now i run OpenSuse 13.1 - an i think that the troubles have gone....

    lets try it again ;-)

    i come back and report all my findings.
    best regards
    metabo


    btw: here the thread with the installation of mozrepl and Mecha::firefox



    How to install Mozrepl on a fresh installed OpenSuse 12.3

    especially: How to install Mozrepl on a fresh installed OpenSuse 12.3

    you keath: I'm running Mac OS 10.8.3 Lion. My system perl is 5.12.4. In November, the installation was flawless. No problems. Tonight, many things went wrong.

    I had errors with MozRepl I believe, and the platform matrix showed errors for Darwin (Mac OS X) with my perl version, so I used perlbrew to upgrade my perl to 5.16.0. Then had other errors. Downgraded MozRepl to an earlier version that had tested good and had an endless stream of "MozRepl-RemoteObject not responding" messages during tests, and couldn't advance.

    MozRepl has a default port number of 4242. Issued this command from the terminal to see if there was a conflict:

    lsof | grep 4242
    System response was:
    Dictation 67779 keath txt REG 1,2 12402 15054242 /System/Library/PrivateFrameworks/SpeechObjects.framework/Versions/A/Frameworks/DictationServices.framework/Versions/A/Resources/dictation_mic_071.tiff
    So yeah, there is a conflict on Mac OS X now because the Dictation framework is listening on that port for speech events. I turned off dictation from the system preferences, and then restarted Firefox.

    Dear Keath - a t the weekend i will try to do it again... hopefully the issues and troubles are gone...

    btw: above all: many many thanks for all your help so far!!
    Last edited by metabo; May 28th, 2014 at 01:34 AM.
  6. #4
  7. !~ /m$/
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    May 2004
    Location
    Reno, NV
    Posts
    4,274
    Rep Power
    0
    Originally Posted by metabo
    I'm running Mac OS 10.8.3 Lion. My system perl is 5.12.4. In November, the installation was flawless. No problems. Tonight, many things went wrong.
    You confused me. I thought you were running Mac OS X for a minute, but you were quoting me.

    Yes, I remember well. Good luck; hope the installation works easily for you this time.
  8. #5
  9. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    dear keath


    well belive it or not - i run into the same issues...


    today i am running opensuse 13.1 -

    and i am trying to install mozrepl and perl

    i did the following
    Code:
    perl -MCPAN -e shell
    cpan> install WWW::Mechanize::Firefox
    - it failed... see

    perl_mecha | Pastebin.de - Share text and code with Pastebin
    Code:
    
      Parse errors: No plan found in TAP output
    t/51-mech-sandbox.t             (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/51-mech-set-content.t         (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/51-mech-submit.t              (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-frame-document.t           (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-frame-event.t              (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-mech-api-find_link-frames.t (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-mech-api-find_link.t       (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-mech-xpath.t               (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-selector-frames.t          (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-selector-noframes.t        (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/52-selector-relative.t        (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/53-mech-capture-js-error.t    (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/55-basic-auth.t               (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/60-mech-cookies.t             (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/60-mech-custom-headers.t      (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/65-is_visible.t               (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/65-mech-meta.t                (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/65-set_visible.t              (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-download-url.t             (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-mech-png.t                 (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-real-status.t              (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-rt70106-reload.t           (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-rt71216.t                  (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-tag-team.t                 (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-two-instances.t            (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/70-urlbar.t                   (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/75-save_url-cookies.t         (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/99-changes.t                  (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: Bad plan.  You planned 2 tests but ran 0.
    t/99-examples.t                 (Wstat: 3328 Tests: 14 Failed: 13)
      Failed tests:  1-11, 13-14
      Non-zero exit status: 13
    t/mechanize/autocheck.t         (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/mechanize/content.t           (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/rt65615.t                     (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/rt78706.t                     (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/rt84418.t                     (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    t/select.t                      (Wstat: 512 Tests: 0 Failed: 0)
      Non-zero exit status: 2
      Parse errors: No plan found in TAP output
    Files=86, Tests=81,  9 wallclock secs ( 0.30 usr  0.09 sys +  7.11 cusr  0.79 csys =  8.29 CPU)
    Result: FAIL
    Failed 81/86 test programs. 14/81 subtests failed.
    make: *** [test_dynamic] Fehler 2
      CORION/WWW-Mechanize-Firefox-0.74.tar.gz
    one dependency not OK (MozRepl::RemoteObject); additionally test harness failed
      /usr/bin/make test -- NOT OK
    //hint// to see the cpan-testers results for installing this module, try:
      reports CORION/WWW-Mechanize-Firefox-0.74.tar.gz
    Running make install
      make test had returned bad status, won't install without force
    Failed during this command:
     ZIGOROU/MozRepl-0.06.tar.gz                  : make_test NO
     CORION/MozRepl-RemoteObject-0.37.tar.gz      : make_test NO one dependency not OK (MozRepl)
     CORION/WWW-Mechanize-Firefox-0.74.tar.gz     : make_test NO one dependency not OK (MozRepl::RemoteObject); additionally test harness failed
    
    cpan[2]>


    Object moved


    I've used this in anger only under Linux.
    The problem (back then) was that the WWW modules didn't include hard dependencies for the MozRepl modules, hence the manual install.
    My own instructions (from about 3 years ago)


    cpan WWW::Mechanize::Firefox
    cpan MozRepl
    cpan MozRepl::RemoteObject
  10. #6
  11. !~ /m$/
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    May 2004
    Location
    Reno, NV
    Posts
    4,274
    Rep Power
    0
    The error message in your paste bin is:

    Code:
    Can't locate MozRepl/RemoteObject.pm in @INC
    Have you tried installing that module directly?

    Code:
    sudo cpan
    install MozRepl::RemoteObject
  12. #7
  13. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    dear keath


    Originally Posted by keath
    The error message in your paste bin is:

    Code:
    Can't locate MozRepl/RemoteObject.pm in @INC
    Have you tried installing that module directly?

    Code:
    sudo cpan
    install MozRepl::RemoteObject
    many thanks - will digg deeper into all that later the weekend.

    come back and report all my findings


    greeting matze
  14. #8
  15. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    Hello dear linux-experts

    i have some consitency-errors within the perl - see below

    Code:
    install_cpan_pre.pl
    
    #!/usr/bin/perl
    
    use strict;
    use warnings;
    use Net::FTP;
    
    use constant HOST  => 'ftp.cpan.org';
    use constant DIR1  => '/pub/CPAN/authors';
    use constant FILE1 => '01mailrc.txt.gz';
    use constant DIR2  => '/pub/CPAN/modules';
    use constant FILE2 => '02packages.details.txt.gz';
    use constant FILE3 => '03modlist.data.gz';
    
    my $ftp = Net::FTP->new(
        HOST, 
        Debug => 0, 
        Passive => 1, 
        Timeout => 1
    );
    
    $ftp->login('anonymous');
    $ftp->cwd(DIR1);
    $ftp->ascii;
    $ftp->get(FILE1);
    $ftp->cwd(DIR2);
    $ftp->get(FILE2);
    $ftp->size(FILE2);
    $ftp->get(FILE3);
    $ftp->quit;
    }
    See how i go on - and what is happening

    Code:
    #!/usr/bin/perl
    
    use strict;
    use warnings;
    use YAML;
    use YAML::Dumper;
    use Parse::CPAN::Authors;
    
    my $list = '/root/01mailrc.txt.gz';
    
    my $p = Parse::CPAN::Authors->new( $list );
    my @authors = $p->authors;
    
    my $dumper = YAML::Dumper->new;
    $dumper->indent_width(1);
    print $dumper->dump({dump => $p}

    some bad things happen


    Code:
    martin@linux-70ce:~/perl> perl cpan2.pl
    Failed to read /root/01mailrc.txt.gz: no permission at /usr/lib/perl5/site_perl/5.18.1/Parse/CPAN/Authors.pm line 22.
    martin@linux-70ce:~/perl>
    guess that i have to put the file into another path

    this one here: /root/01mailrc.txt.gz:

    what do you say?`
  16. #9
  17. !~ /m$/
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    May 2004
    Location
    Reno, NV
    Posts
    4,274
    Rep Power
    0
    I don't know what you are trying to accomplish. Are you trying to install code on a remote machine?
  18. #10
  19. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    hello dear keath - i stuck now - i think that i need your help. How can i install it on a local machine (opensuse 13.1)
    By the way: can i create a CD with all the ingedients on it :

    - Mozilla
    - perl
    - Mozrepl

    [in other words - like a knoppix or something like that]
    Background: i guess that it is probaly easier to go this way - since it is tooo hard to install it on a machine!?

    What do you think - is there a way to go round the issues i have all the times?

    Love to hear from you

    greetings
  20. #11
  21. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    hello dear keath - i stuck now - i think that i need your help. How can i install it on a local machine (opensuse 13.1)
    By the way: can i create a CD with all the ingedients on it :

    - Mozilla
    - perl
    - Mozrepl

    [in other words - like a knoppix or something like that]
    Background: i guess that it is probaly easier to go this way - since it is tooo hard to install it on a machine!?

    What do you think - is there a way to go round the issues i have all the times?

    Love to hear from you

    greetings
  22. #12
  23. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    364
    Rep Power
    0
    sooory sooory for duplicate post.

    @themods plz do not throw me out of this g reat forum
    Last edited by metabo; June 26th, 2014 at 12:01 PM.
  24. #13
  25. !~ /m$/
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    May 2004
    Location
    Reno, NV
    Posts
    4,274
    Rep Power
    0
    I doubt a CD is the answer. A disk would have to be built with an installer for all the specific modules and software you want, built for the specific machine and operating system you are using. Needs that specific will require you to build the disk. If you can't build the software in the first place, I don't see it as possible.

    You didn't provide any error message this time, so I have no idea if the problem is due to versions, permissions, tools, or something else. I'm sure we could figure it out if we were in the same room together, but we are failing to communicate through the forum.

    I think your best bet would be to look for a user group that might be able to give you some hands-on instruction. For example, here is a list of perl groups. There might be one in your area:

    Perl Mongers

    I've seen you posting in the PHP forum also, so check them out too.

    PHP UserGroup

    I hope you'll find one you can attend.

IMN logo majestic logo threadwatch logo seochat tools logo