我在我的机器上运行 Solaris,我需要安装 Date::Calc perl 模块才能让我的脚本之一工作。
当我运行以下命令时:
sudo perl -MCPAN -e 'install Date::Calc'
我收到以下错误:
Tests succeeded but one dependency not OK (Bit::Vector)
STBEY/Date-Calc-6.3.tar.gz
[dependencies] -- NA
Running make install
make test had returned bad status, won't install without force
我以前没有 Perl 开发经验,所以我不知道错误可能是什么或从哪里获得更多信息。
我应该怎么做才能解决这个问题?
尝试先安装 Bit::Vector 时,即运行以下命令时:
sudo perl -MCPAN -e 'install Bit::Vector'
我收到以下错误消息:
Checking if your kit is complete...
Looks good
Writing Makefile for Bit::Vector
Writing patchlevel.h for /usr/bin/perl (5.012003)
cp lib/Bit/Vector/Overload.pm blib/lib/Bit/Vector/Overload.pm
cp Vector.pm blib/lib/Bit/Vector.pm
cp Vector.pod blib/lib/Bit/Vector.pod
cp lib/Bit/Vector/Overload.pod blib/lib/Bit/Vector/Overload.pod
cp lib/Bit/Vector/String.pod blib/lib/Bit/Vector/String.pod
cp lib/Bit/Vector/String.pm blib/lib/Bit/Vector/String.pm
cc -c -DPTR_IS_LONG -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPERL_USE_SAFE_PUTENV -xO4 -DVERSION=\"7.2\" -DXS_VERSION=\"7.2\" -KPIC "-I/usr/perl5/5.12/lib/i86pc-solaris-64int/CORE" BitVector.c
sh: line 1: cc: not found
*** Error code 127
make: Fatal error: Command failed for target `BitVector.o'
STBEY/Bit-Vector-7.2.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
我通过以下命令安装了 gcc(如此处的建议):
pkg install gcc-45
pkg install system/header
但是在尝试安装 Bit::Vector 时我仍然遇到同样的错误。事实上,当我cc
在命令行上键入时,我得到了command not found
错误。但是,当我键入gcc
时,我得到gcc: no input files
.