首页 > 解决方案 > CPAN 安装模块 Math::Pari 失败(获取 GP/PARI)

问题描述

我在 linux (debian buster) 上,目前正在尝试安装 perl 模块 'Crypt::Random',它依赖于 'Math::Pari':

/usr/bin/perl -MCPAN -e 'install Crypt::Random'

获取 GP/PARI 时失败:

Reading '/root/.cpan/Metadata'
  Database was generated on Sat, 13 Feb 2021 13:17:03 GMT
Running install for module 'Crypt::Random'
Checksum for /root/.cpan/sources/authors/id/V/VI/VIPUL/Crypt-Random-1.52.tar.gz ok
Configuring V/VI/VIPUL/Crypt-Random-1.52.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Warning: prerequisite Math::Pari 2.001804 not found.
Generating a Unix-style Makefile
Writing Makefile for Crypt::Random
Writing MYMETA.yml and MYMETA.json
  VIPUL/Crypt-Random-1.52.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for V/VI/VIPUL/Crypt-Random-1.52.tar.gz
---- Unsatisfied dependencies detected during ----
----      VIPUL/Crypt-Random-1.52.tar.gz      ----
    Math::Pari [requires]
Running install for module 'Math::Pari'
Checksum for /root/.cpan/sources/authors/id/I/IL/ILYAZ/modules/Math-Pari-2.030518.zip ok
Configuring I/IL/ILYAZ/modules/Math-Pari-2.030518.zip with Makefile.PL
Did not find GP/PARI build directory around.

Do you want to me to fetch GP/PARI automatically?

  (If you do not, you will need to fetch it manually, and/or direct me to
   the directory with GP/PARI source via the command-line option paridir=/dir)

Make sure you have a large scrollback buffer to see the messages, or `tee'
the STDOUT/STDERR to a file.

Fetch? (y/n, press Enter) y
Getting GP/PARI from ftp://megrez.math.u-bordeaux.fr/pub/pari/
Cannot create FTP object: Connection timed out at utils/Math/PariBuild.pm line 446.

Can't fetch file with Net::FTP, now trying with LWP::UserAgent...
Can't fetch directory listing from ftp://megrez.math.u-bordeaux.fr/pub/pari/: 500 Connection timed out
Client-Date: Sat, 13 Feb 2021 15:23:12 GMT    

...

Not in this directory, trying `http://megrez.math.u-bordeaux.fr/pub/pari/'...
Can't fetch directory listing from http://megrez.math.u-bordeaux.fr/pub/pari/: 500 Can't connect to megrez.math.u-bordeaux.fr:80 (Connection timed out)
Content-Type: text/plain
Client-Date: Sat, 13 Feb 2021 15:34:08 GMT
Client-Warning: Internal response

Can't connect to megrez.math.u-bordeaux.fr:80 (Connection timed out)

Connection timed out at /usr/share/perl5/LWP/Protocol/http.pm line 50.

...

这需要相当长的时间(它正在尝试通过 ftp 和 http / LWP 的不同路径),然后以一种无休止的循环结束:

Not in this directory, trying `'...
Can't fetch directory listing from : 400 URL missing
Content-Type: text/plain
Client-Date: Sat, 13 Feb 2021 15:43:50 GMT
Client-Warning: Internal response

400 URL missing

使用 Ctrl+C 取消它可以继续安装,但由于缺少模块 Mth::Pari 而失败。

我尝试使用不同的工具(ftp http)和不同的网络(DSL 和移动设备)连接到域,但域似乎没有响应。

有谁知道,那里发生了什么?

如果域无法访问(我是 perl 和 CPAN 的新手,在网上搜索时还没有找到任何提示),是否有另一种方法可以安装缺少的模块?

提前感谢您的提示!

标签: perlcpan

解决方案


推荐阅读