Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^2: Can't install CPAN modules

by hsfrey (Beadle)
on Oct 13, 2011 at 01:41 UTC ( #931122=note: print w/replies, xml ) Need Help??


in reply to Re: Can't install CPAN modules
in thread Can't install CPAN modules

Thank you. When I enter that command, the reply is "No missing packages to install", which would lead one to believe that the module is installed properly.

But, when I put code like:

use MATH::Random; $a = random_uniform(45); print "\na=$a";
I get an error message:
Can't locate loadable object for module Math::Random in @INC

In perl/lib/Math I have a file named Random.pl
I have other pieces of the download scattered all around the disc, since I had no idea what was supposed to go where.

If ppm could find the module, why couldn't perl?

Replies are listed 'Best First'.
Re^3: Can't install CPAN modules
by keszler (Priest) on Oct 13, 2011 at 02:18 UTC

    I suspect that your earlier efforts to install put the Perl wrapper files in place - enough to confuse ppm - but not the compiled files. (In my site/lib/auto/Math/Random directory are Random.bs, Random.dll, Random.exp, and Random.lib.)

    Try ppm install --force Math::Random - the force option will make ppm replace whatever is currently in place.

Re^3: Can't install CPAN modules
by Marshall (Canon) on Oct 13, 2011 at 04:52 UTC
    I agree with keszler that previous attempts have your Perl installation a bit confused.

    In the future, I recommend using the graphical version of ppm (Active State's Perl package manager). typing simplly "ppm" at the command prompt without parameters will start the GUI version. "ppm help" gives help for the command line version, but for most simple things the GUI is easier to use.

    If you have really messed things up, un-install Perl (via the normal add/remove program way) and re-install Active State's Perl, then use ppm for all future package installations. This will save many hours of frustration on your end!

Re^3: Can't install CPAN modules
by FunkyMonk (Chancellor) on Oct 13, 2011 at 15:13 UTC

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (5)
As of 2021-11-30 19:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?