真是不甘心啊~~~不过看现在的情况,只有安装sun的cc了(将近五百兆o_O 正在下载......)。
这个问题还是open状态,如果哪位有在solaris下用gcc(而非solaris的cc)编译perl模块的经验,还请指教。 On Sep 14, 12:19 pm, "woosley. xu." <[email protected]> wrote: > export CC=gcc? > 我以前也尝试用gcc编译过solaris下的模块 > 问题的确很多,最后还是安装了个sun的cc > > 在 2010年9月14日 上午11:50,ZHANG Jiaqiang A <[email protected] > > > > >写道: > > > 我猜想会不会因为Config.pm里面的信息有不统一的地方呢?问题是如何确定该修改哪个Config.pm文件,另外该如何修改Config.pm文件呢? > > > 昨天我安装了某个模块后,(不记得具体是哪个了) 再调用perlgcc > > Makefile.PL的时候就总会开始出现下面的warning,以这次编译ExtUtils-ParseXS-2.2206为例: > > > # perlgcc Makefile.PL > > Have /usr/perl5/5.8.4/lib/Sun/Solaris/PerlGcc > > Want /usr/perl5/5.8.4/lib/sun4-solaris-64int > > Your perl and your Config.pm seem to have different ideas about the > > architecture they are running on. > > Perl thinks: [PerlGcc] > > Config says: [sun4-solaris-64int] > > This may or may not cause problems. Please check your installation of perl > > if you have problems building this extension. > > Writing Makefile for ExtUtils::ParseXS > > > 我刚才查看测试文件more.t,应该是在38行的have_comiler(ExtUtils::CBuilder)的时候返回空,所以把相关编译的cases都跳过了。看文档ExtUtils::CBuilder是从Config.pm > > 读取编译工具的相关信息。我猜想我的编译方式比较特殊(在Solaris下用gcc编译而不是cc),所以它没能找到gcc ? > > > =============more.t============================== > > 33 my $quiet = $ENV{PERL_CORE} && !$ENV{HARNESS_ACTIVE}; > > 34 my $b = ExtUtils::CBuilder->new(quiet => $quiet); > > 35 > > 36 SKIP: { > > * 37 skip "no compiler available", 2 > > 38 if ! $b->have_compiler;* > > 39 $obj_file = $b->compile( source => $source_file ); > > 40 ok $obj_file; > > 41 ok -e $obj_file, "Make sure $obj_file exists"; > > 42 } > > > ------------------------------ > > *From:* ZHANG Jiaqiang A > > *Sent:* 2010年9月14日 10:47 > > *To:* '[email protected]' > > *Subject:* RE: [PerlChina] 安装Log-Dispatch-2.26模块 make test出错 > > > 多谢,这回执行成功了。 > > > 似乎前面的很多case都跳过去了,没找到编译器么?这台机器安装的是标准solaris,莫非是root的环境变量弄得不对? > > > # perl -Mlib=./lib,./blib/lib,./blib/arch t/more.t > > 1..25 > > ok 1 - require ExtUtils::ParseXS; > > ok 2 - Create an output file > > ok 3 # skip no compiler available > > ok 4 # skip no compiler available > > ok 5 # skip no dynamic loading > > ok 6 # skip no dynamic loading > > ok 7 # skip no dynamic loading > > ok 8 # skip no dynamic loading > > ok 9 # skip no dynamic loading > > ok 10 # skip no dynamic loading > > # Looks like you planned 25 tests but ran 10. > > > # which gcc > > /usr/sfw/bin/gcc > > # gcc -v > > Reading specs from /usr/sfw/lib/gcc/sparc-sun-solaris2.10/3.4.3/specs > > Configured with: > > /sfw10/builds/build/sfw10-patch/usr/src/cmd/gcc/gcc-3.4.3/configure > > --prefix=/usr/sfw --with-as=/usr/ccs/bin/as --without-gnu-as > > --with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++ > > --enable-shared > > Thread model: posix > > gcc version 3.4.3 (csl-sol210-3_4-branch+sol_rpath) > > # env > > HOME=/root > > HZ= > > LD_LIBRARY_PATH=/usr/local/lib > > LOGNAME=root > > MAIL=/var/mail/root > > PATH=/usr/sbin:/usr/bin:/usr/sfw/bin:/usr/ccs/bin:/usr/perl5/bin > > SHELL=/sbin/sh > > TERM=xterm > > TZ=PRC > > > -- > > 您收到此邮件是因为您订阅了 Google 网上论坛的"PerlChina Mongers 讨论组"论坛。 > > 要向此网上论坛发帖,请发送电子邮件至 [email protected]。 > > 要取消订阅此网上论坛,请发送电子邮件至 > > [email protected]<perlchina%[email protected]> > > 。 > > 若有更多问题,请通过http://groups.google.com/group/perlchina?hl=zh-CN访问此网上论坛。 > > -- > Woosley.Xu -- 您收到此邮件是因为您订阅了 Google 网上论坛的“PerlChina Mongers 讨论组”论坛。 要向此网上论坛发帖,请发送电子邮件至 [email protected]。 要取消订阅此网上论坛,请发送电子邮件至 [email protected]。 若有更多问题,请通过 http://groups.google.com/group/perlchina?hl=zh-CN 访问此网上论坛。
