Perl:安装 CPAN 模块时出错
我在 Mac OS X 10.5 上运行,我想用 Perl 编写一个程序。但是,我需要安装模块 RDF::Trine 和 DBD::CSV 当我安装两者时出现错误。
如果我写:
install RDF::Trine
错误是:
Files=51, Tests=5, 2 wallclock secs ( 0.21 usr 0.18 sys + 1.30 cusr 0.51 csys = 2.20 CPU) Result: FAIL Failed 49/51 test programs. 5/5 subtests failed. make: *** [test_dynamic] Error 2 /usr/bin/make test -- NOT OK Running make install make test had returned bad status, won't install without force
安装 DBD::CSV 的错误是:
Files=21, Tests=18, 1 wallclock secs ( 0.10 usr 0.08 sys + 0.85 cusr 0.26 csys = 1.29 CPU) Result: FAIL Failed 16/21 test programs. 2/18 subtests failed. make: *** [test_dynamic] Error 255 /usr/bin/make test -- NOT OK Running make install make test had returned bad status, won't install without force
你有解决方案吗?
I run on Mac OS X 10.5 and I want to write a program in Perl. However, I need to install the module RDF::Trine and DBD::CSV and I got an error when I install both.
If I write :
install RDF::Trine
The error is :
Files=51, Tests=5, 2 wallclock secs ( 0.21 usr 0.18 sys + 1.30 cusr 0.51 csys = 2.20 CPU) Result: FAIL Failed 49/51 test programs. 5/5 subtests failed. make: *** [test_dynamic] Error 2 /usr/bin/make test -- NOT OK Running make install make test had returned bad status, won't install without force
And the error for the installation of DBD::CSV is :
Files=21, Tests=18, 1 wallclock secs ( 0.10 usr 0.08 sys + 0.85 cusr 0.26 csys = 1.29 CPU) Result: FAIL Failed 16/21 test programs. 2/18 subtests failed. make: *** [test_dynamic] Error 255 /usr/bin/make test -- NOT OK Running make install make test had returned bad status, won't install without force
Do you have a solution for me?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您能否发布以下内容的输出:
甚至
很多的 perl 开发人员在 MacOS 上开发。如果它不能开箱即用,我会感到惊讶。
更新后,这里的 cpan 输出比注释中更容易阅读。看起来您的 cpan 设置为忽略依赖项:
precessions_policy
是控制此行为的配置变量。通过运行
o conf prescriptives_policy
确认设置,如果它设置为ask
以外的任何内容,请运行:(这些是小写字母“oh”)
然后重复您的 cpan 命令。
Can you post the output of:
or even
A LOT of perl developers develop on MacOS. I'd be surprised if it didn't work out of the box.
Updated, easier to read cpan output here than in a comment. It looks like your cpan is set to ignore dependencies:
prerequisites_policy
is the configuration variable that controls this behavior.Confirm the setting by running
o conf prerequisites_policy
and if it's set to anything other thanask
, run:(Those are lowercase letter "oh")
Then repeat your cpan commands.
您可以强制安装perl模块
其中 RDF::Trine 是模块名称
You can install perl module forcefully
Where RDF::Trine is the module name