我在跑..。
..。而且我似乎无法通过使用"cpan“工具获得LWP::Simple安装。当我试图这么做的时候,我会收到.
cpan[1]> install LWP::Simple
Reading '/root/.cpan/Metadata'
Database was generated on Mon, 20 Jan 2014 11:17:02 GMT
Running install for module 'LWP::Simple'
Running make for G/GA/GAAS/libwww-perl-6.05.tar.gz
Checksum for /root/.cpan/sources/authors/id/G/GA/GAAS/libwww-perl-6.05.tar.gz ok
Scanning cache /root/.cpan/build for sizes
............................................................................DONE
CPAN.pm: Building G/GA/GAAS/libwww-perl-6.05.tar.gz
Can't connect: IO::Socket::INET: connect: Invalid argument
The can-we-talk-to-ourself test failed.
Checking if your kit is complete...
Looks good
Warning: prerequisite HTML::Entities 0 not found.
Warning: prerequisite HTML::HeadParser 0 not found.
Writing Makefile for LWP
Could not read metadata file. Falling back to other methods to determine prerequisites
---- Unsatisfied dependencies detected during ----
---- GAAS/libwww-perl-6.05.tar.gz ----
HTML::Entities [requires]
HTML::HeadParser [requires]
Running make test
Delayed until after prerequisites
Running make install
Delayed until after prerequisites
Running install for module 'HTML::Entities'
Running make for G/GA/GAAS/HTML-Parser-3.71.tar.gz
Checksum for /root/.cpan/sources/authors/id/G/GA/GAAS/HTML-Parser-3.71.tar.gz ok
CPAN.pm: Building G/GA/GAAS/HTML-Parser-3.71.tar.gz
Checking if your kit is complete...
Looks good
Processing hints file hints/solaris.pl
Writing Makefile for HTML::Parser
cp lib/HTML/PullParser.pm blib/lib/HTML/PullParser.pm
cp Parser.pm blib/lib/HTML/Parser.pm
cp lib/HTML/Entities.pm blib/lib/HTML/Entities.pm
cp lib/HTML/LinkExtor.pm blib/lib/HTML/LinkExtor.pm
cp lib/HTML/TokeParser.pm blib/lib/HTML/TokeParser.pm
cp lib/HTML/HeadParser.pm blib/lib/HTML/HeadParser.pm
cp lib/HTML/Filter.pm blib/lib/HTML/Filter.pm
/usr/perl5/5.12/bin/perl mkhctype >hctype.h
/usr/perl5/5.12/bin/perl mkpfunc >pfunc.h
/usr/perl5/5.12/bin/perl /usr/perl5/5.12/lib/ExtUtils/xsubpp -typemap /usr/perl5/5.12/lib/ExtUtils/typemap -typemap typemap Parser.xs > Parser.xsc && mv Parser.xsc Parser.c
cc -c -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPERL_USE_SAFE_PUTENV -xO4 -DVERSION=\"3.71\" -DXS_VERSION=\"3.71\" -KPIC "-I/usr/perl5/5.12/lib/sun4-solaris-64int/CORE" -DMARKED_SECTION Parser.c
sh: line 1: cc: not found
*** Error code 127
make: Fatal error: Command failed for target `Parser.o'
GAAS/HTML-Parser-3.71.tar.gz
/usr/bin/make -- NOT OK
'YAML' not installed, will not store persistent state
Running make test
Can't test without successful make
Running make install
Make had returned bad status, install seems impossible
Running install for module 'HTML::HeadParser'
Running make for G/GA/GAAS/HTML-Parser-3.71.tar.gz
Has already been unwrapped into directory /root/.cpan/build/HTML-Parser-3.71-gMF8Mw
Could not make: Unknown error
Running make test
Can't test without successful make
Running make install
Make had returned bad status, install seems impossible
Running make for G/GA/GAAS/libwww-perl-6.05.tar.gz
Has already been unwrapped into directory /root/.cpan/build/libwww-perl-6.05-HwKLBD
CPAN.pm: Building G/GA/GAAS/libwww-perl-6.05.tar.gz
Warning: Prerequisite 'HTML::Entities => 0' for 'GAAS/libwww-perl-6.05.tar.gz' failed when processing 'GAAS/HTML-Parser-3.71.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
Warning: Prerequisite 'HTML::HeadParser => 0' for 'GAAS/libwww-perl-6.05.tar.gz' failed when processing 'GAAS/HTML-Parser-3.71.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
cp lib/LWP/RobotUA.pm blib/lib/LWP/RobotUA.pm
cp lib/LWP/Debug.pm blib/lib/LWP/Debug.pm
cp lib/LWP/Authen/Ntlm.pm blib/lib/LWP/Authen/Ntlm.pm
cp lib/LWP.pm blib/lib/LWP.pm
cp lib/LWP/Protocol.pm blib/lib/LWP/Protocol.pm
cp lib/LWP/ConnCache.pm blib/lib/LWP/ConnCache.pm
cp lwptut.pod blib/lib/lwptut.pod
cp lib/LWP/Protocol/ftp.pm blib/lib/LWP/Protocol/ftp.pm
cp lib/LWP/Authen/Digest.pm blib/lib/LWP/Authen/Digest.pm
cp lib/LWP/Protocol/gopher.pm blib/lib/LWP/Protocol/gopher.pm
cp lib/LWP/Protocol/cpan.pm blib/lib/LWP/Protocol/cpan.pm
cp lwpcook.pod blib/lib/lwpcook.pod
cp lib/LWP/Protocol/file.pm blib/lib/LWP/Protocol/file.pm
cp lib/LWP/Protocol/GHTTP.pm blib/lib/LWP/Protocol/GHTTP.pm
cp lib/LWP/DebugFile.pm blib/lib/LWP/DebugFile.pm
cp lib/LWP/Protocol/data.pm blib/lib/LWP/Protocol/data.pm
cp lib/LWP/Protocol/nogo.pm blib/lib/LWP/Protocol/nogo.pm
cp lib/LWP/Authen/Basic.pm blib/lib/LWP/Authen/Basic.pm
cp lib/LWP/Protocol/nntp.pm blib/lib/LWP/Protocol/nntp.pm
cp lib/LWP/UserAgent.pm blib/lib/LWP/UserAgent.pm
cp lib/LWP/Simple.pm blib/lib/LWP/Simple.pm
cp lib/LWP/Protocol/loopback.pm blib/lib/LWP/Protocol/loopback.pm
cp lib/LWP/Protocol/mailto.pm blib/lib/LWP/Protocol/mailto.pm
cp lib/LWP/Protocol/http.pm blib/lib/LWP/Protocol/http.pm
cp lib/LWP/MemberMixin.pm blib/lib/LWP/MemberMixin.pm
cp bin/lwp-dump blib/script/lwp-dump
/usr/perl5/5.12/bin/perl -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/lwp-dump
cp bin/lwp-mirror blib/script/lwp-mirror
/usr/perl5/5.12/bin/perl -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/lwp-mirror
cp bin/lwp-download blib/script/lwp-download
/usr/perl5/5.12/bin/perl -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/lwp-download
cp bin/lwp-request blib/script/lwp-request
/usr/perl5/5.12/bin/perl -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/lwp-request
Manifying blib/man1/lwp-dump.1
Manifying blib/man1/lwp-mirror.1
Manifying blib/man1/lwp-download.1
Manifying blib/man1/lwp-request.1
Manifying blib/man3/LWP::RobotUA.3
Manifying blib/man3/LWP::Debug.3
Manifying blib/man3/lwpcook.3
Manifying blib/man3/LWP::Authen::Ntlm.3
Manifying blib/man3/LWP.3
Manifying blib/man3/LWP::ConnCache.3
Manifying blib/man3/LWP::Protocol.3
Manifying blib/man3/lwptut.3
Manifying blib/man3/LWP::Simple.3
Manifying blib/man3/LWP::UserAgent.3
Manifying blib/man3/LWP::MemberMixin.3
GAAS/libwww-perl-6.05.tar.gz
/usr/bin/make -- OK
Running make test
/usr/perl5/5.12/bin/perl t/TEST 0
base/protocols.t ...... ok
base/ua.t ............. 1/35 # Failed test 13 in base/ua.t at line 56
# base/ua.t line 56 is: ok($res->header("Content-Style-Type", "text/css"));
# Failed test 14 in base/ua.t at line 57
# base/ua.t line 57 is: ok($res->header("Content-Script-Type", "text/javascript"));
base/ua.t ............. Failed 2/35 subtests
robot/ua-get.t ........ skipped: Can't talk to ourself (misconfigured system)
robot/ua.t ............ skipped: Can't talk to ourself (misconfigured system)
local/autoload-get.t .. Failed 1/1 subtests
local/autoload.t ...... 1/1 # Failed test 1 in local/autoload.t at line 22
# local/autoload.t line 22 is: ok($response->is_success);
local/autoload.t ...... Failed 1/1 subtests
local/get.t ........... ok
local/http.t .......... skipped: Can't talk to ourself (misconfigured system)
local/protosub.t ...... ok
Test Summary Report
-------------------
base/ua.t (Wstat: 0 Tests: 35 Failed: 2)
Failed tests: 13-14
local/autoload-get.t (Wstat: 0 Tests: 1 Failed: 1)
Failed test: 1
local/autoload.t (Wstat: 0 Tests: 1 Failed: 1)
Failed test: 1
Files=9, Tests=51, 4 wallclock secs ( 0.27 usr 0.09 sys + 3.04 cusr 0.34 csys = 3.74 CPU)
Result: FAIL
Failed 3/9 test programs. 4/51 subtests failed.
*** Error code 255
make: Fatal error: Command failed for target `test'
GAAS/libwww-perl-6.05.tar.gz
2 dependencies missing (HTML::HeadParser,HTML::Entities); additionally test harness failed
/usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
reports GAAS/libwww-perl-6.05.tar.gz
Running make install
make test had returned bad status, won't install without force
Failed during this command:
GAAS/HTML-Parser-3.71.tar.gz : make NO
GAAS/libwww-perl-6.05.tar.gz : make_test NO 2 dependencies missing (HTML::HeadParser,HTML::Entities); additionally test harness failed
cpan[2]>
怎么回事?
我意识到可能有一些失败促成了这一点。
谢谢你,盖瑞
发布于 2014-01-20 22:00:41
查看您的第一条错误消息:
cc -c -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPERL_USE_SAFE_PUTENV -xO4 -DVERSION=\"3.71\" -DXS_VERSION=\"3.71\" -KPIC "-I/usr/perl5/5.12/lib/sun4-solaris-64int/CORE" -DMARKED_SECTION Parser.c
sh: line 1: cc: not found
*** Error code 127
HTML::解析器的某些部分是LWP::Simple的先决条件,是用C编写的,需要一个c编译器,您还没有安装它。
发布于 2014-03-12 17:01:50
当我在openindiana和编译lwp时遇到类似的问题时,我看到了这篇文章。下面博客中的包装器实际上解决了我刚才输入的/usr/bin/cc中的所有问题,并且非常幸运。希望它能帮助其他有问题的人。
http://blog.zorinaq.com/?e=30
如果博客消失了,这里是python代码包装器。
#!/usr/bin/python
# cc(1) wrapper to build CPAN Perl modules with GCC on OpenSolaris. -mrb
import os, sys
path = '/usr/bin/gcc'
args = []
i = 0
while i < len(sys.argv):
if i == 0:
args.append(path)
elif sys.argv[i] == '-KPIC':
args.append('-fPIC')
elif sys.argv[i] == '-xO3':
args.append('-O3')
elif sys.argv[i] == '-xspace':
pass
elif sys.argv[i] == '-xildoff':
pass
else:
args.append(sys.argv[i])
i += 1
os.execv(path, args)
发布于 2014-02-04 06:16:00
如果您希望在支持的perl树中构建要安装的CPAN模块,则需要使用Solaris Studio 12.1 (对于Solaris 11和11.1)。您可以从Guntram提到的url下载此文件。
https://stackoverflow.com/questions/21245002
复制相似问题