Skip Menu |

This queue is for tickets about the ExtUtils-Install CPAN distribution.

Report information
The Basics
Id: 33795
Status: resolved
Priority: 0/
Queue: ExtUtils-Install

People
Owner: Nobody in particular
Requestors: jdhedden [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in:
  • 1.47
  • 1.49
Fixed in: 1.50



Subject: [PATCH] 'make test' failures on Win32/Cygwin
'make test' for ExtUtils-Install produces the following: t/can_write_dir...... # Failed test at t/can_write_dir.t line 48. # Structures begin differing at: # $got->[0] = '1' # $expected->[0] = '0' # Failed test at t/can_write_dir.t line 49. # Structures begin differing at: # $got->[0] = '1' # $expected->[0] = '0' # Looks like you failed 2 tests of 13. Dubious, test returned 2 (wstat 512, 0x200) Failed 2/13 subtests This is caused by the fact that POSIX::access is broken for Win32 and Cygwin: It returns "0 but true" for both writable and non-writable directories. The attached patch corrects the problem by forcing the use of (-w $dir) on Win32 and Cygwin.
Subject: ExtUtils-Install.patch
--- ExtUtils-Install/lib/ExtUtils/Install.pm +++ ExtUtils-Install/lib/ExtUtils/Install.pm @@ -351,7 +351,7 @@ my $has_posix; sub _have_write_access { my $dir=shift; - if (!defined $has_posix) { + if (!$Is_cygwin && !$Is_Win32 && !defined $has_posix) { $has_posix=eval 'local $^W; require POSIX; 1' || 0; } if ($has_posix) {
Subject: Re: [rt.cpan.org #33795] [PATCH] 'make test' failures on Win32/Cygwin
Date: Tue, 4 Mar 2008 17:15:52 +0100
To: bug-ExtUtils-Install [...] rt.cpan.org
From: demerphq <demerphq [...] gmail.com>
On 04/03/2008, Jerry D. Hedden via RT <bug-ExtUtils-Install@rt.cpan.org> wrote: Show quoted text
> > Tue Mar 04 10:21:52 2008: Request 33795 was acted upon. > Transaction: Ticket created by JDHEDDEN > Queue: ExtUtils-Install > Subject: [PATCH] 'make test' failures on Win32/Cygwin > Broken in: 1.47, 1.49 > Severity: Important > Owner: Nobody > Requestors: jdhedden@cpan.org > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=33795 > > > > 'make test' for ExtUtils-Install produces the following: > > t/can_write_dir...... > # Failed test at t/can_write_dir.t line 48. > # Structures begin differing at: > # $got->[0] = '1' > # $expected->[0] = '0' > > # Failed test at t/can_write_dir.t line 49. > # Structures begin differing at: > # $got->[0] = '1' > # $expected->[0] = '0' > # Looks like you failed 2 tests of 13. > Dubious, test returned 2 (wstat 512, 0x200) > Failed 2/13 subtests > > This is caused by the fact that POSIX::access is broken > for Win32 and Cygwin: It returns "0 but true" for both > writable and non-writable directories. > > The attached patch corrects the problem by forcing the > use of (-w $dir) on Win32 and Cygwin.
Ill investigate further, but I do my development on Win32 and all tests passed fine there. Are you running as administrator or something like that? Yves -- perl -Mre=debug -e "/just|another|perl|hacker/"
Subject: Re: [rt.cpan.org #33795] [PATCH] 'make test' failures on Win32/Cygwin
Date: Tue, 4 Mar 2008 12:26:12 -0500
To: bug-ExtUtils-Install [...] rt.cpan.org
From: "Jerry D. Hedden" <jdhedden [...] cpan.org>
Show quoted text
> Ill investigate further, but I do my development on Win32 and all > tests passed fine there.
I only added the Win32 part because Steve Hay reported failures similar to mine in Win32 smokes. I assumed it was the same thing, but it seems his further investigations so it's not, so disregard the Win32 part. Show quoted text
> Are you running as administrator or something like that?
Yes, I run with administrator privileges, but I can't see how that affects how POSIX::access operates. If I create a dir and chmod 555, (-w $dir) is false, but POSIX::access($dir, POSIX::W_OK()) returns '0 but true'. If I chmod 777, (-w $dir) is 1 (true), but POSIX::access($dir, POSIX::W_OK()) still returns '0 but true'. What is the issue with precluding the use of POSIX::access() under Cygwin?
CC: pp <perl5-porters [...] perl.org>
Subject: Re: [rt.cpan.org #33795] [PATCH] 'make test' failures on Win32/Cygwin
Date: Fri, 7 Mar 2008 08:52:25 +0100
To: bug-ExtUtils-Install [...] rt.cpan.org
From: demerphq <demerphq [...] gmail.com>
On 04/03/2008, Jerry D. Hedden via RT <bug-ExtUtils-Install@rt.cpan.org> wrote: Show quoted text
> > Queue: ExtUtils-Install > > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=33795 > > >
> > Ill investigate further, but I do my development on Win32 and all
> > tests passed fine there.
> > > I only added the Win32 part because Steve Hay reported > failures similar to mine in Win32 smokes. I assumed it was > the same thing, but it seems his further investigations so > it's not, so disregard the Win32 part. > >
> > Are you running as administrator or something like that?
> > > Yes, I run with administrator privileges, but I can't see > how that affects how POSIX::access operates. > > If I create a dir and chmod 555, (-w $dir) is false, but > POSIX::access($dir, POSIX::W_OK()) returns '0 but true'. > > If I chmod 777, (-w $dir) is 1 (true), but > POSIX::access($dir, POSIX::W_OK()) still returns > '0 but true'. > > What is the issue with precluding the use of POSIX::access() > under Cygwin?
Nothing, i just wanted to get to the bottom of things, IOW, you say its bad, and someone else says its ok, and on my box it worked fine... Thus there is some kind of mismatch. And if its due to some local issue on your box i dont want to disadvantage others. So if we are all happy that cygwin should not use POSIX::access then im fine with that change. Yves -- perl -Mre=debug -e "/just|another|perl|hacker/"
Can this be closed now?
Subject: Re: [rt.cpan.org #33795] [PATCH] 'make test' failures on Win32/Cygwin
Date: Wed, 5 Nov 2008 17:35:01 -0500
To: bug-ExtUtils-Install [...] rt.cpan.org
From: "Jerry D. Hedden" <jdhedden [...] cpan.org>
Yves via RT wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=33795 > > > Can this be closed now?
Yes. It appears to be fixed in v1.50. Thanks.
thanks for the report