Interesting excuse to go delving through the CPAN.pm source code. I also had alterior motives. I wanted to see how to change the order of which facility is used to fetch modules. I have CPAN 1.63 and ActivePerl build 5.6.1 633 on Windows 2000

My conclusion is that you may have differences in the Cygwin install on the machines. That is, the error comes from tar.exe or something it depends on.

Here is why I think that:

  • CPAN.pm relies on the external tar program. It executes the following code to untar a module
    5746 $system = "$CPAN::Config->{tar} xvf $file"; 5747 $CPAN::Frontend->myprint(qq{Using Tar:$system:\n}); 5748 if (system($system)==0) { 5749 $CPAN::Frontend->myprint(qq{Untarred $file successfull +y\n}); 5750 } else { 5751 $CPAN::Frontend->mydie(qq{Couldn\'t untar $file\n}); 5752 }
    As far as I know system() on win32 has no problems with people using either forward slashes or back slashes in paths
  • After doing all my reading of CPAN.pm I reread your post and realised that this line in the output gives it away
    /usr/bin/tar: F\:\\.cpan\\sources\\authors\\id\\M\\MS\\MSCHWERN\\Carp- +Assert-0.17.tar: Cannot open: I/O error

    tar.exe is saying cannot open due to I/O error

  • The next thing is my experiences with CPAN.pm on the win32 platform. I downloaded the Cygwin platform to do another project and I tried to use the tar.exe from it in my CPAN sessions. I get this
    Using Tar:c:\cygwin\bin\tar.exe xvf \.cpan\sources\authors\id\M\MS\MSC +HWERN\Carp -Assert-0.17.tar: Carp-Assert-0.17/ Carp-Assert-0.17/t/ Carp-Assert-0.17/t/30no_disabled.t /usr/bin/tar: Skipping to next header /usr/bin/tar: Error exit delayed from previous errors Couldn't untar \.cpan\sources\authors\id\M\MS\MSCHWERN\Carp-Assert-0.1 +7.tar cpan>

    After searching around I found an alterative tar.exe which I use now. It works OK except when you specify the full path to it. When you do you get an error locating cygwin.dll. <sigh>

    So basically tar.exe on Win32 with Cygwin sucks and I still wish I could throw Windows out and use linux (even better: Solaris on a Blade so I can finish my Sun Admin certification. :-)

    --blm--

    In reply to Re: CPAN weirdness on Win32 by blm
    in thread CPAN weirdness on Win32 by demerphq

    Title:
    Use:  <p> text here (a paragraph) </p>
    and:  <code> code here </code>
    to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.