系统:debian 7 x64 RC 1 Perl版本:v5.14.2
当试图安装MIME ::工具,我不能得到它正确的编译。
cpan[4]> install MIME::Tools Going to read '/root/.cpan/Metadata' Database was generated on Sat, 13 Apr 2013 01:41:02 GMT Running install for module 'MIME::Tools' Running make for D/DS/DSKOLL/MIME-tools-5.504.tar.gz Checksum for /root/.cpan/sources/authors/id/D/DS/DSKOLL/MIME-tools-5.504.tar.gz ok Scanning cache /root/.cpan/build for sizes ........................................................................----DONE DEL(1/14): /root/.cpan/build/libwww-perl-6.05-ZDaNp5 DEL(2/14): /root/.cpan/build/File-Scan-ClamAV-1.91-Ti5677 DEL(3/14): /root/.cpan/build/Crypt-OpenSSL-Random-0.04-5B9ULy DEL(4/14): /root/.cpan/build/Crypt-OpenSSL-RSA-0.28-04I5K5 DEL(5/14): /root/.cpan/build/Mail-DKIM-0.40-fzAICY DEL(6/14): /root/.cpan/build/Net-CIDR-Lite-0.21-2WIaXR DEL(7/14): /root/.cpan/build/Sys-Hostname-Long-1.4-DgtI9U DEL(8/14): /root/.cpan/build/Mail-SPF-Query-1.999.1-RlMA1a DEL(9/14): /root/.cpan/build/Mail-SPF-Query-1.999.1-gfsVza DEL(10/14): /root/.cpan/build/Net-DNS-Resolver-Programmable-v0.003-Wuv2JV DEL(11/14): /root/.cpan/build/Mail-SPF-v2.8.0-yUk_ZP DEL(12/14): /root/.cpan/build/MLDBM-2.05-UYpHDK DEL(13/14): /root/.cpan/build/Mail-SRS-0.31-F9Cxsm DEL(14/14): /root/.cpan/build/Net-IP-Match-Regexp-1.01-I3a1Pe CPAN.pm: Going to build D/DS/DSKOLL/MIME-tools-5.504.tar.gz Checking if your kit is complete... Looks good Writing Makefile for MIME::Tools Writing MYMETA.yml and MYMETA.json cp lib/MIME/Body.pm blib/lib/MIME/Body.pm cp lib/MIME/Decoder/Gzip64.pm blib/lib/MIME/Decoder/Gzip64.pm cp lib/MIME/Field/ContDisp.pm blib/lib/MIME/Field/ContDisp.pm cp lib/MIME/Parser/Results.pm blib/lib/MIME/Parser/Results.pm cp lib/MIME/Field/ContType.pm blib/lib/MIME/Field/ContType.pm cp lib/MIME/Decoder/NBit.pm blib/lib/MIME/Decoder/NBit.pm cp lib/MIME/Entity.pm blib/lib/MIME/Entity.pm cp lib/MIME/Head.pm blib/lib/MIME/Head.pm cp lib/MIME/Parser/Filer.pm blib/lib/MIME/Parser/Filer.pm cp lib/MIME/Words.pm blib/lib/MIME/Words.pm cp lib/MIME/Field/ParamVal.pm blib/lib/MIME/Field/ParamVal.pm cp lib/MIME/Decoder/BinHex.pm blib/lib/MIME/Decoder/BinHex.pm cp lib/MIME/Field/ConTraEnc.pm blib/lib/MIME/Field/ConTraEnc.pm cp lib/MIME/Tools.pm blib/lib/MIME/Tools.pm cp lib/MIME/Decoder/Binary.pm blib/lib/MIME/Decoder/Binary.pm cp lib/MIME/Decoder.pm blib/lib/MIME/Decoder.pm cp lib/MIME/Decoder/UU.pm blib/lib/MIME/Decoder/UU.pm cp lib/MIME/Decoder/QuotedPrint.pm blib/lib/MIME/Decoder/QuotedPrint.pm cp lib/MIME/Decoder/Base64.pm blib/lib/MIME/Decoder/Base64.pm cp lib/MIME/WordDecoder.pm blib/lib/MIME/WordDecoder.pm cp lib/MIME/Parser.pm blib/lib/MIME/Parser.pm cp lib/MIME/Parser/Reader.pm blib/lib/MIME/Parser/Reader.pm Manifying blib/man3/MIME::Decoder::Gzip64.3pm Manifying blib/man3/MIME::Body.3pm Manifying blib/man3/MIME::Field::ContDisp.3pm Manifying blib/man3/MIME::Parser::Results.3pm Manifying blib/man3/MIME::Field::ContType.3pm Manifying blib/man3/MIME::Decoder::NBit.3pm Manifying blib/man3/MIME::Entity.3pm Manifying blib/man3/MIME::Parser::Filer.3pm Manifying blib/man3/MIME::Head.3pm Manifying blib/man3/MIME::Words.3pm Manifying blib/man3/MIME::Field::ParamVal.3pm Manifying blib/man3/MIME::Decoder::BinHex.3pm Manifying blib/man3/MIME::Field::ConTraEnc.3pm Manifying blib/man3/MIME::Tools.3pm Manifying blib/man3/MIME::Decoder::Binary.3pm Manifying blib/man3/MIME::Decoder.3pm Manifying blib/man3/MIME::Decoder::UU.3pm Manifying blib/man3/MIME::Decoder::Base64.3pm Manifying blib/man3/MIME::Decoder::QuotedPrint.3pm Manifying blib/man3/MIME::WordDecoder.3pm Manifying blib/man3/MIME::Parser::Reader.3pm Manifying blib/man3/MIME::Parser.3pm DSKOLL/MIME-tools-5.504.tar.gz /usr/bin/make -- OK Running make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t t/02-kwalitee.t ................... skipped: Test::Kwalitee not installed; skipping t/02-pod-coverage.t ............... skipped: Test::Pod::Coverage disabled. TEST_POD_COVERAGE=1 if you want it. t/02-pod.t ........................ skipped: Test::Pod 1.00 required for testing POD t/99-prepare.t .................... ok t/attachment-filename-encoding.t .. ok t/Body.t .......................... ok t/BodyPrint.t ..................... ok t/Decoder.t ....................... # Using gzip: 1 t/Decoder.t ....................... ok t/EmptyPart.t ..................... ok t/Entity.t ........................ ok t/Filer.t ......................... ok t/Gauntlet.t ...................... ok t/Head.t .......................... ok t/Misc.t .......................... ok t/ParamVal.t ...................... ok t/Parser.t ........................ ok t/ParserEncoded.t ................. ok t/ParserPreamble.t ................ ok t/Ref.t ........................... ok t/Smtpsend.t ...................... accept failed: Connection timed out at t/Smtpsend.t line 61. # Looks like your test exited with 110 before it could output anything. t/Smtpsend.t ...................... Dubious, test returned 110 (wstat 28160, 0x6e00) Failed 9/9 subtests t/ticket-11901.t .................. ok t/ticket-22684.t .................. ok t/ticket-37139.t .................. ok t/ticket-41632.t .................. ok t/ticket-43439.t .................. ok t/ticket-52924.t .................. ok t/ticket-5462.t ................... ok t/ticket-60931.t .................. ok t/ticket-65681.t .................. ok t/ticket-66025.t .................. ok t/ticket-71041.t .................. ok t/ticket-71677.t .................. ok t/ticket-80433.t .................. ok t/WordDecoder.t ................... ok t/WordEncoder.t ................... ok t/Words.t ......................... ok Test Summary Report ------------------- t/Smtpsend.t (Wstat: 28160 Tests: 0 Failed: 0) Non-zero exit status: 110 Parse errors: Bad plan. You planned 9 tests but ran 0. Files=36, Tests=386, 26 wallclock secs ( 0.25 usr 0.37 sys + 2.79 cusr 1.00 csys = 4.41 CPU) Result: FAIL Failed 1/36 test programs. 0/386 subtests failed. make: *** [test_dynamic] Error 255 DSKOLL/MIME-tools-5.504.tar.gz /usr/bin/make test -- NOT OK //hint// to see the cpan-testers results for installing this module, try: reports DSKOLL/MIME-tools-5.504.tar.gz Running make install make test had returned bad status, won't install without force Failed during this command: DSKOLL/MIME-tools-5.504.tar.gz : make_test NO
所以这失败了:
t/Smtpsend.t ...................... accept failed: Connection timed out at t/Smtpsend.t line 61. # Looks like your test exited with 110 before it could output anything. t/Smtpsend.t ...................... Dubious, test returned 110 (wstat 28160, 0x6e00)
我确实发现了一些关于这个问题的东西 ,但是没用。 它表示要从这改变代码
# In the parent my $s = $sock->accept(); if (!$s) { kill(9, $pid); die("accept failed: $!"); }
对此
sleep 1; # In the parent my $s = $sock->accept(); if (!$s) { kill(9, $pid); die("accept failed: $!"); }
但我的代码是这样的
# In the parent my $s = $sock->accept(); if (!$s) { sleep(1); $s = $sock->accept(); if (!$s) { kill(9, $pid); die("accept failed: $!"); } }
虽然我确实sleep 1;了一sleep 1; 在评论之前(尽pipe我怀疑这个新版本的睡眠是在这种情况下添加的),但它仍然没有正确编译。
有什么想法吗 ?
谢谢!
你得到它正确的编译 ,它只是失败了一个testing! 更多的人抱怨testing失败,例如在这里看到。 你可能不应该太担心。 这意味着你可以强制安装包,它应该都可以工作。
但是一般来说,如果你使用系统的perl尝试通过你的软件包pipe理器来安装尽可能多的软件包(如果可能的话) – 这也可以解决你的问题。 在Debian上就像
apt-get install libmime-tools-perl
你完成了!
我有同样的问题和调查,我认为我已经确定了根本原因。
我分离出了服务器和客户端代码,以摆脱任何时间问题,并发现客户端或发送端延迟了大约30秒,尝试使用Mail :: Util中的mailaddress()函数来识别发件人。
所以我find的解决方法如下:在Smtpsend.t的开始处,即在使用语句之后添加以下行,
$ ENV {MAILDOMAIN} ='example.com';
testing仍然需要13秒钟才能运行,但成功完成。 你当然可以在你的shell中设置这个环境variables,但我对可以随包发布的解决scheme感兴趣。
让我知道这是否适用于您的环境。 我在OSX上运行。
我会提出一个与Mime :: Tools工具的问题。