我正在运行 Debian 9 x64,我想在 perl 中运行一个需要 MIME::Lite 模块的小脚本。要安装它,请运行此命令:
perl -MCPAN -e 'install MIME::Lite'
这是结果:
root@XutiHTPC:/home/xuti# perl -MCPAN -e 'install MIME::Lite'
Reading '/root/.cpan/Metadata'
Database was generated on Fri, 15 Jun 2018 10:41:02 GMT
Running install for module 'MIME::Lite'
Checksum for /root/.cpan/sources/authors/id/R/RJ/RJBS/MIME-Lite-3.030.tar.gz ok
'YAML' not installed, will not store persistent state
Configuring R/RJ/RJBS/MIME-Lite-3.030.tar.gz with Makefile.PL
MIME::Lite is designed to take advantage of a variety of external modules
if they are not present then MIME::Lite will attempt to do its best
but its strongly recommend that you install them.
These modules are:
MIME::Types
Mail::Address
I can add these modules to the prereq list which will cause the files to be
automatically installed if they aren't already present
Add prereqs? [Yes]
Checking if your kit is complete...
Looks good
Warning: prerequisite Email::Date::Format 1.000 not found.
Warning: prerequisite MIME::Types 1.28 not found.
Warning: prerequisite Mail::Address 1.62 not found.
Generating a Unix-style Makefile
Writing Makefile for MIME::Lite
Writing MYMETA.yml and MYMETA.json
RJBS/MIME-Lite-3.030.tar.gz
/usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for R/RJ/RJBS/MIME-Lite-3.030.tar.gz
---- Unsatisfied dependencies detected during ----
---- RJBS/MIME-Lite-3.030.tar.gz ----
Mail::Address [requires]
Email::Date::Format [requires]
MIME::Types [requires]
Running install for module 'Mail::Address'
Checksum for /root/.cpan/sources/authors/id/M/MA/MARKOV/MailTools-2.20.tar.gz ok
Configuring M/MA/MARKOV/MailTools-2.20.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Warning: prerequisite Date::Format 0 not found.
Warning: prerequisite Date::Parse 0 not found.
Generating a Unix-style Makefile
Writing Makefile for MailTools
Writing MYMETA.yml and MYMETA.json
MARKOV/MailTools-2.20.tar.gz
/usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for M/MA/MARKOV/MailTools-2.20.tar.gz
---- Unsatisfied dependencies detected during ----
---- MARKOV/MailTools-2.20.tar.gz ----
Date::Format [requires]
Date::Parse [requires]
Running install for module 'Date::Format'
Checksum for /root/.cpan/sources/authors/id/G/GB/GBARR/TimeDate-2.30.tar.gz ok
Configuring G/GB/GBARR/TimeDate-2.30.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Date::Parse
Writing MYMETA.yml and MYMETA.json
GBARR/TimeDate-2.30.tar.gz
/usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for G/GB/GBARR/TimeDate-2.30.tar.gz
GBARR/TimeDate-2.30.tar.gz
make -- NOT OK
Running install for module 'Date::Parse'
GBARR/TimeDate-2.30.tar.gz
Has already been unwrapped into directory /root/.cpan/build/TimeDate-2.30-WvSQXd
GBARR/TimeDate-2.30.tar.gz
Has already been prepared
GBARR/TimeDate-2.30.tar.gz
Could not make: Unknown error
MARKOV/MailTools-2.20.tar.gz
Has already been unwrapped into directory /root/.cpan/build/MailTools-2.20-noZ3M9
MARKOV/MailTools-2.20.tar.gz
Has already been prepared
Running make for M/MA/MARKOV/MailTools-2.20.tar.gz
Warning: Prerequisite 'Date::Format => 0' for 'MARKOV/MailTools-2.20.tar.gz' failed when processing 'GBARR/TimeDate-2.30.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
Warning: Prerequisite 'Date::Parse => 0' for 'MARKOV/MailTools-2.20.tar.gz' failed when processing 'GBARR/TimeDate-2.30.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
MARKOV/MailTools-2.20.tar.gz
make -- NOT OK
Running install for module 'Email::Date::Format'
Checksum for /root/.cpan/sources/authors/id/R/RJ/RJBS/Email-Date-Format-1.005.tar.gz ok
Configuring R/RJ/RJBS/Email-Date-Format-1.005.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Email::Date::Format
Writing MYMETA.yml and MYMETA.json
RJBS/Email-Date-Format-1.005.tar.gz
/usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for R/RJ/RJBS/Email-Date-Format-1.005.tar.gz
RJBS/Email-Date-Format-1.005.tar.gz
make -- NOT OK
Running install for module 'MIME::Types'
Checksum for /root/.cpan/sources/authors/id/M/MA/MARKOV/MIME-Types-2.17.tar.gz ok
Configuring M/MA/MARKOV/MIME-Types-2.17.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for MIME::Types
Writing MYMETA.yml and MYMETA.json
MARKOV/MIME-Types-2.17.tar.gz
/usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for M/MA/MARKOV/MIME-Types-2.17.tar.gz
MARKOV/MIME-Types-2.17.tar.gz
make -- NOT OK
RJBS/MIME-Lite-3.030.tar.gz
Has already been unwrapped into directory /root/.cpan/build/MIME-Lite-3.030-bAZrWv
RJBS/MIME-Lite-3.030.tar.gz
Has already been prepared
Running make for R/RJ/RJBS/MIME-Lite-3.030.tar.gz
Warning: Prerequisite 'MIME::Types => 1.28' for 'RJBS/MIME-Lite-3.030.tar.gz' failed when processing 'MARKOV/MIME-Types-2.17.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
Warning: Prerequisite 'Mail::Address => 1.62' for 'RJBS/MIME-Lite-3.030.tar.gz' failed when processing 'MARKOV/MailTools-2.20.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
Warning: Prerequisite 'Email::Date::Format => 1.000' for 'RJBS/MIME-Lite-3.030.tar.gz' failed when processing 'RJBS/Email-Date-Format-1.005.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
RJBS/MIME-Lite-3.030.tar.gz
make -- NOT OK
我尝试安装先决条件 MIME::Types 和 Mail::Address 但没有成功,MARKOV/MailTools 失败。
有什么建议吗?
非常感谢
最佳答案
我发现了问题。在安装任何新的 PERL 模块之前,Linux 必须安装 MAKE。我的 debian 9 安装是全新的,没有安装 make 命令。我跑了
apt-get install make
还有 perl 模块
perl -MCPAN -e 'install Net::SMTPS'
并且有效!
谢谢你的时间
关于linux - 安装 Perl 模块 MIME::Lite 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50874664/