0

System: debian 7 x64 RC 1 Perl Version:v5.14.2

When trying to install MIME::Tools I can't get it to properly compile.

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

So this fails at:

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)

I did find something regarding this problem but it was of no use. It stated to change the code from this

# In the parent
my $s = $sock->accept();
if (!$s) {
    kill(9, $pid);
    die("accept failed: $!");
}

to this

sleep 1;

# In the parent
my $s = $sock->accept();
if (!$s) {
    kill(9, $pid);
    die("accept failed: $!");

}

but my code is like this

# In the parent
my $s = $sock->accept();
if (!$s) {
        sleep(1);
        $s = $sock->accept();
        if (!$s) {
                kill(9, $pid);
                die("accept failed: $!");
        }
}

and although I did put a sleep 1; before the comment (although I suspect that in this newer version the sleep was added in the condition) it it still did not compile properly.

Any thoughts ?

Thanks!

2 Answers 2

3

You get it to compile properly, it just fails one test! More people complain about the test failing, see for instance here. You probably should not worry that much about it. This means you can force install the package and it should all just work.

But in general, if you use the system perl try to install as much packages via your package manager if possible - this would also work around your issue. On Debian it's as simple as

apt-get install libmime-tools-perl

and you're done!

1
  • Installing libmime-tools-perl via apt solved this issue. Apr 15, 2013 at 7:17
1

I have the same issue and on investigation I think I have identified the root cause.

I separated out the server and client code to get rid of any timing issues and found that the client or sending side was getting delayed for about 30 seconds trying to identify the sender using the mailaddress() function from Mail::Util.

So the workaround that I have found is the following, At the start of Smtpsend.t, i.e. just after the use statements add the following line,

$ENV{MAILDOMAIN} = 'example.com';

The test still takes 13 odd seconds to run but it completes successfully. You could of course just set this environment variable in your shell, but I was interested in a solution that could be distributed with the package.

Let me know if this works in your environment. I am running on OSX.

I will raise an issue with the Mime::Tools guys.

1
  • I'm sorry to answer this late but it appears that now it's working fine. Thank you! Jun 5, 2013 at 19:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .