Reputation: 33
I'm running...
... and I can't seem to get LWP::Simple installed by using the "cpan" tool. When I attempt to do so, I receive...
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]>
What gives?
I realize there may be a few failures contributing to this.
Thanks in advance, Gary
Upvotes: 0
Views: 3788
Reputation: 11
Ran across this post when i was having a similar problem with openindiana and compiling lwp. The wrapper in the blog below actually solved all my problems I just put in /usr/bin/cc and have had great luck. Hope it helps anyone else having the problem.
In case the blog ever goes away here is the python code wrapper
#!/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)
Upvotes: 1
Reputation: 2576
If you want to build CPAN modules to install in the supported perl tree, then you need to use Solaris Studio 12.1 ( for Solaris 11 and 11.1). You can download this from the url which Guntram mentioned.
Upvotes: 0
Reputation: 9819
Look at your first error message:
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
Some parts of HTML::Parser, which is a prerequisite to LWP::Simple, are written in C and need a c compiler, which you don't have installed.
Upvotes: 1