好的,我知道如何使用 cpan 安装 Perl 模块,并且已经这样做很多年了。但是当我尝试在这台特定的 Mac 上安装 DateTime 模块时,它失败了,声称找不到编译器。
以下是尝试安装先决条件之一 Params::Validate 的一些输出:(我在尝试安装相关模块时遇到了相同类型的错误。)
Configuring Params-Validate-1.00
Running Build.PL
/usr/libexec/gcc/powerpc-apple-darwin10/4.2.1/as: assembler (/usr/bin/../libexec/gcc/darwin/ppc/as or /usr/bin/../local/libexec/gcc/darwin/ppc/as) for architecture ppc not installed
Installed assemblers are:
/usr/bin/../libexec/gcc/darwin/x86_64/as for architecture x86_64
/usr/bin/../libexec/gcc/darwin/i386/as for architecture i386
lipo: can't open input file: /var/tmp//cc3Aefez.out (No such file or directory)
Warning: ExtUtils::CBuilder not installed or no compiler detected
Proceeding with configuration, but compilation may fail during Build
为什么 Build.PL 正在寻找 ppc 编译器?如果这是问题所在,我在哪里告诉它(或 cpan 或 cpanm)这台机器不是 ppc 盒子?
我运行的是 10.6.8。 perl 的版本是为 darwin-thread-multi-2level 构建的 v5.10.0
我肯定已经安装了开发者工具。
我通过 sudo 运行 cpan 和 cpanm。
如果任何人能够提供任何帮助,我将不胜感激。
最佳答案
- known problem with Xcode on Lion ,Apple 忍不住搞乱了
nm
,再次破坏了 Perl ( previously ),谁知道还有什么 - p5p discussion
- perlbrew's info
关于macos - 如何在 Mac OSX 10.6 上安装 Perl DateTime 模块,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8492164/