develooper Front page | perl.perl5.porters | Postings from March 2006

Re: Making IO::Socket pass test on Win32

Thread Previous | Thread Next
From:
Andrew Dougherty
Date:
March 31, 2006 08:17
Subject:
Re: Making IO::Socket pass test on Win32
Message ID:
Pine.SOC.4.62.0603311116470.28515@maxwell.phys.lafayette.edu
On Fri, 31 Mar 2006, demerphq wrote:

> On 3/31/06, Steve Hay <steve.hay@uk.radan.com> wrote:
> > demerphq wrote:
> > > diff -burd d:\.cpan\build\IO-1.23\/t/io_sock.t IO-1.23/t/io_sock.t
> > > --- d:\.cpan\build\IO-1.23\/t/io_sock.t       2006-03-26 04:27:13.000000000 +0200
> > > +++ IO-1.23/t/io_sock.t       2006-03-26 14:47:08.034134600 +0200
> > > @@ -17,7 +17,7 @@
> > >      elsif ($ENV{PERL_CORE} and $Config{'extensions'} !~ /\bIO\b/) {
> > >       $reason = 'IO extension unavailable';
> > >      }
> > > -    elsif (! $Config{'d_fork'}) {
> > > +    elsif (! $Config{'d_fork'} && $^O ne "MSWin32" ) {
> > >       $reason = 'no fork';
> > >      }
> > >      if ($reason) {
> >
> > This bit makes io_sock.t fail tests 2-26 when using a non-threaded perl
> > on Win32:
> >
> > C:\p5p\bleadperl\t>.\perl -I..\lib ..\ext\IO\t\io_sock.t
> > 1..26
> > ok 1
> > The fork function is unimplemented at ..\ext\IO\t\io_sock.t line 59.
> 
> Any recommendation on a better Config test to use?

Config{d_fork} is the correct test to use to see if you have fork().  If
a platform configuration system doesn't set d_fork correctly, I'd say the 
bug is in the configuration system.

-- 
    Andy Dougherty		doughera@lafayette.edu

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About