问题
I am trying to install Crypt::Random module, a cryptographically secure random number generator, and says it requires Math::Pari 2.001802, which is not availible from cpan.org, but says it is available from this other URL, which does not work. I tried to install them both anyway and encountered this problem:
C:\Users\Jlinne\Documents> cpanm Crypt::Random
--> Working on Crypt::Random
Fetching http://www.cpan.org/authors/id/V/VI/VIPUL/Crypt-Random-1.25.tar.gz ... OK
Configuring Crypt-Random-1.25 ... OK
==> Found dependencies: Math::Pari
--> Working on Math::Pari
Fetching http://www.cpan.org/authors/id/I/IL/ILYAZ/modules/Math-Pari-2.01080900.zip ... OK
Configuring Math-Pari-2.01080900 ... N/A
! Configure failed for Math-Pari-2.01080900. See C:\Users\Jlinne\.cpanm\work\1476250290.12460\build.log for details.
! Installing the dependencies failed: Module 'Math::Pari' is not installed
! Bailing out the installation for Crypt-Random-1.25.
C:\Users\Jlinne\Documents> cpanm Math::Pari
--> Working on Math::Pari
Fetching http://www.cpan.org/authors/id/I/IL/ILYAZ/modules/Math-Pari-2.01080900.zip ... OK
Configuring Math-Pari-2.01080900 ... N/A
! Configure failed for Math-Pari-2.01080900. See C:\Users\Jlinne\.cpanm\work\1476250325.1340\build.log for details.
The build.log does not help me either, any other possible ways to install this module successfully? Thanks.
回答1:
You will have to share the build.log
file. Without that we cannot check what caused the failure.
BTW for Math::Pari you need PARI library. Starting from version 2.0, this module comes without a PARI library included.
Since you are trying to install Math-Pari-2.01080900, therefore you will first have to install PARI library.
Get it from http://pari.math.u-bordeaux.fr/download.html
回答2:
If you're ok with using 32 bit Perl, you could use 32 bit Strawberry Perl, which already has both Math::Pari and Crypt::Random modules installed.
Unfortunately the 64 bit versions of Strawberry Perl do not include either of these modules. In that case, you'll have to follow the suggestion from Chankey Pathak about installing the PARI library in order to install the Math::Pari module.
来源:https://stackoverflow.com/questions/39991235/unable-to-install-mathpari-module