Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re^2: cpanplus not functioning right in a multiple-Perl installation setup?

by HelenCr (Monk)
on May 09, 2013 at 17:35 UTC ( #1032804=note: print w/ replies, xml ) Need Help??


in reply to Re: cpanplus not functioning right in a multiple-Perl installation setup?
in thread cpanplus not functioning right in a multiple-Perl installation setup?

Khen1950fx: I ran your program. Here is the output:

Database was generated on Wed, 08 May 2013 21:53:13 GMT Term::ReadLine is up to date (1.10). Running install for module 'Term::ReadLine::Gnu' Running make for H/HA/HAYASHI/Term-ReadLine-Gnu-1.20.tar.gz Fetching with LWP: http://cpan.strawberryperl.com/authors/id/H/HA/HAYASHI/Term-ReadLine-G +nu-1.20.tar.gz Fetching with LWP: http://cpan.strawberryperl.com/authors/id/H/HA/HAYA +SHI/CHECKSUMS Checksum for F:\...\SBPerl\cpan\sources\authors\id\H\HA\HAYASHI\Term-R +eadLine-Gnu-1.20.tar.gz ok CPAN.pm: Building H/HA/HAYASHI/Term-ReadLine-Gnu-1.20.tar.gz Could not find neither libtermcap.a, libncurses.a, or libcurses. Warning: No success on command[F:\...\SBPerl\perl\bin\perl.exe Makefil +e.PL] HAYASHI/Term-ReadLine-Gnu-1.20.tar.gz F:\...\SBPerl\perl\bin\perl.exe Makefile.PL -- NOT OK Stopping: 'install' failed for 'Term::ReadLine::Gnu'.

What to do?

Many TIA - Helen

Update:
I ran your program with Term::ReadLine::Perl instead of: Term::ReadLine::Gnu, and it responded with:

Database was generated on Wed, 08 May 2013 21:53:13 GMT Term::ReadLine is up to date (1.10). Term::ReadLine::Perl is up to date (1.0303). Term::UI is up to date (0.34).

So this looks ok.

And now, when I run cpanp, it's not complaining that "terminal is not fully functional". Which is good.
Correction: sorry, that problem is still there.

But this was not the main, original problem. The main problem was, that CPANPLUS was not recognizing the new Perl installation, although I've changed the "PATH" in the right way.

I'll try using cpanp again, and report back.

Many thanks - Helen


Comment on Re^2: cpanplus not functioning right in a multiple-Perl installation setup?
Select or Download Code
Re^3: cpanplus not functioning right in a multiple-Perl installation setup?
by Corion (Pope) on May 09, 2013 at 18:51 UTC
    And now, when I run cpanp, it's not complaining that "terminal is not fully functional". Which is good. Correction: sorry, that problem is still there.

    Doesn't this give you pause?

    Because the steps of installing Term::ReadLine et al. were exactly to make the cpanp program shut up about not having readline functionality.

    I would, as I already recommended, make triply certain that the correct Perl is finding the correct CPANPLUS module and the correct CPANPLUS configurations and that no trace of the other Perl installation is found in:

    • The environment. See perlrun for the interesting parts.
    • Configuration files. Maybe use App::Ack or maybe use the Windows "Search in Files" facilities for offending files.

    As the setup of more than one Perl version seems to be problematic for you, maybe you want to reconsider the decision of trying to maintain two versions of Perl on the same machine?

      It turns out that the "terminal is not fully functional" warning is a known problem with the "terminal" after installing Strawberry Perl. See comment #48 here: https://groups.google.com/forum/?fromgroups=#!topic/msysgit/chXoBxQ3c0Y where he says: I had this issue after installing Strawberry Perl. See also comment #47 there.

      I deleted the TERM environment variable, and then cpanplus is not complaining: "terminal is not fully functional" any more. So this does solve that problem.

      Like I said, this leaves us with the main issue: how to make cpanplus refer to a new Perl installation only. Here is some additional information:

      %PATH%: echo %PATH% gives:

      F:\Win7programs\SBPerl\ is where I've installed Strawberry Perl 5.16.3.
      (My older 5.14.2 Perl installation is at: F:\Win7programs\Dwimperl\)

      Interestingly, from the old installation, there exists a directory structure on C:\

      C:\Documents and Settings\Helen\.cpanplus \5.14.2 \build \authors \id \install-logs

      but there is no similar sub-directory structure for the new installation: \5.16.3

      Also, strangely, even if I call cpanp like so (as Corion suggested):
      >F:\Win7programs\SBPerl\perl\bin\cpanp.bat
      it still checks the old Perl installation for the existence of modules, and writes the install log to:
      C:\Documents and Settings\Helen\.cpanplus\install-logs

      Here is a typical (one-liner) install log:
      [MSG] [Thu May  9 21:40:21 2013] Module 'Carp' already up to date, won't install without force

      IMO, the key questions here are:

      1. How does cpanp determine the location of \perl\bin and \perl\site\bin;
      2. How does cpanp determine whether a module is installed (or not)
      Is there a configuration file for cpanp? If so, where is it located?

      Many TIA - Helen

      N.B. Corion: you said: As the setup of more than one Perl version seems to be problematic for you ...etc
      Installing the second Perl installation, I do not think I have done anything less accurate or orderly that a veteran Perl system manager would have done. But Corion, more generally, I was of the opinion that the PerlMonks spirit is: The only stupid question is the question not asked, and that PerlMonks encourage exploration of the Perl eco-system, and enhancement of Perl knowledge (especially in these times, when the mass hype is to go the Python way (or Ruby, or Lua)).

      I think my posts here definitely have value, and specifically regarding this current cpanp issue, I think I have identified a bug in CPANPLUS, where it has difficulty identifying the default Perl installation in a multi-Perl installation setup.

      If my questions here constitute a nuisance, I can find other forums to gain knowledge at.

        Most likely, CPANPLUS stores user configuration data where all programs store user configuration data. In a directory below $ENV{USERPROFILE}. In your case, I would look at files below C:\Documents and Settings\Helen\.cpanplus.

        Most likely, the config files there reference the "other" directories. But then, I already recommended using a "search in files" facility in my previous post. My guess is that there are configuration settings in one file there that still have the values for the "other" Perl.

        My issue is not with how you installed your second Perl instance, but with your steps to diagnose the issue. The answers to your key questions are likely answered by reading the documentation of CPANPLUS. It's good that you repeat these questions here, but I think you could also find the answers. You may consider it a bug that CPANPLUS maybe follows whatever is specified in its configuration files, or that CPANPLUS only keeps one configuration file per user instead of keeping one per user-per Perl version. But you've already been told what facility of your operating system could help you find out more about where such configuration could be found, or if the "search-in-files" functionality does not work, what other approaches there are.

        You could also review the output of the installation process and check what directories are named there. This could have led you to a diagnosis at least one round of trying to install modules earlier.

        Note that by installing modules with a newer Perl version into the "other" directories, you most likely now have broken the "older" Perl installation, at least if you used the newer Perl to install modules which require a C compiler, like Wx. I recommend looking for a backup of that "other" directory.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1032804]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (19)
As of 2014-07-24 21:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (167 votes), past polls