From: Steve Hay Date: Thu, 13 Jan 2005 10:24:13 +0000 (+0000) Subject: Fix Win32 build problem caused by change 23757 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=679f4c1f843301b32867fd4e42cf54109af3830f;p=p5sagit%2Fp5-mst-13.2.git Fix Win32 build problem caused by change 23757 Change 23757 added a glob() call to win32/FindExt.pm. That code is run by miniperl.exe when making the ..\config.sh target, but miniperl.exe is built with -D PERL_EXTERNAL_GLOB so it requires perlglob.exe to do the glob(). perlglob.exe has been built, but is in the top-level of the source tree so is not found when miniperl.exe is executed from within the win32/ sub-directory. This was causing smokes to fail on t/lib/commonsense.t because the "extensions" field in lib/Config_heavy.pl only contained "threads/shared" as a result of the glob() not finding anything. Manual builds had been working fine for me because I had an installed perl in my PATH so perlglob.exe was being found there instead! p4raw-id: //depot/perl@23785 --- diff --git a/win32/FindExt.pm b/win32/FindExt.pm index 62429a5..b42b68a 100644 --- a/win32/FindExt.pm +++ b/win32/FindExt.pm @@ -76,7 +76,10 @@ sub is_static # NOTE: recursion limit of 10 to prevent runaway in case of symlink madness sub find_ext { - for my $xxx (glob "*") { + opendir my $dh, '.'; + my @items = grep { !/^\.\.?$/ } readdir $dh; + closedir $dh; + for my $xxx (@items) { if ($xxx ne "DynaLoader") { if (-f "$xxx/$xxx.xs") { $ext{"$_[0]$xxx"} = $static{"$_[0]$xxx"} ? 'static' : 'dynamic';