I am running with Perl 5.10.1 instal开发者_JAVA技巧led using the package manager. I have successfully installed Moose from the CPAN shell, and I have tried to install the MooseX::Declare extention without success.. Here is what I have done:
$ sudo cpan > cpan.log
cpan[1]> install MooseX::Declare
Cannot determine perl version info from lib/MooseX/Declare.pm
Warning: prerequisite Devel::Declare 0.005011 not found.
Warning: prerequisite MooseX::Method::Signatures 0.30 not found.
This is what appears in the terminal at first before the installation lauches, I have posted the 'cpan.log' file here.
Now, I have tried installing the two prereqs above, the latter depends on the first one. But installing the first one gives me this:
cpan[6]> install Devel::Declare
Running install for module 'Devel::Declare'
Running make for F/FL/FLORA/Devel-Declare-0.006000.tar.gz
Has already been unwrapped into directory /home/jfb/.cpan/build/Devel-Declare-0.006000-6qeuWN
'/usr/bin/perl Makefile.PL INSTALLDIRS=site' returned status 512, won't make
Running make test
Make had some problems, won't test
Running make install
Make had some problems, won't install
It would appear that MooseX::Declare
does not list the module named aliased
as a dependency, while using it. Try install aliased
from the CPAN shell, then try installing MooseX::Declare
again.
I had similar problems a few days ago, on OS X. In my case, either MooseX::Method::Signatures
or MooseX::Declare
depended on B::Hooks::OP::Check. Once I installed that, all problems went away.
I have resolved this issue, with good advice from Ether. What happened is that the YAML prerequesite was not installed/not installed properly. What I did is to start over by deleting the build folder and reinstalling:
$ sudo rm /home/jfb/.cpan/build -rf
$ sudo cpan > cpan.log
cpan[1]> install YAML
cpan[2]> install MooseX::Declare
Now everything seems to work, see the log file here.
I had to force install Test::Pod before MooseX::Declare would install in a VM running rPath version 1.0.7 and Perl v5.8.7. After that, and after blowing away the CPAN build directory (per Kaeso's suggestion), MooseX::Declare installed without any problems.
I had installed Moose earlier and that went well.
精彩评论