Mail Archives: djgpp/2008/04/17/15:45:52
"Robbie Hatley" <see DOT my DOT signature AT for DOT my DOT email DOT address> wrote in
news:CuSdnZLhluU2BZrVnZ2dnUVZ_oaonZ2d AT giganews DOT com:
>
> "A. Sinan Unur" wrote:
>> On a hunch, could you check what the following script prints:
>>
>> #!/usr/bin/perl
>>
>> use strict;
>> use warnings;
>>
>> use Fcntl;
>>
>> my $EXLOCK = eval {
>> local $SIG{__DIE__} = sub {};
>> local $SIG{__WARN__} = sub {};
>> &Fcntl::O_EXLOCK();
>> };
>>
>> print "'$EXLOCK'\n";
>>
>> __END__
>
> Hmmm. That gives:
>
> cwd = C:\
> $p einval.p
> Use of uninitialized value in concatenation (.) or string at
> C:\scripts\einval.p line 14.
> ''
> So it's just printing '', since $EXLOCK is uninitialized.
> Whatever that indicates. I'm afraid its going way over my head.
That indicates that the problem flag is one of the other ones.
Here is my guess, File::Temp is OK, but Pod::Perldoc only seems to
check and take care of the shortcomings of Win32. However, the same
shortcomings exist in DJGPP running on Win32 as well. I did look at
MSWin_perldoc_tempfile in Perldoc.pm and it looks like the DJGPP
would need special handling as well.
The only Win32 specific part of the special handling seems to be
getting the tick count for generating a unique filename.
I don't have a DJGPP environment set up right now so I can't test a
patch, but, if you don't care much about filenames being
unguessable, replacing the filename generation algorithm to
something along the lines of
sub DJGPP_perldoc_tempfile {
# skip, see sub MSWin_perldoc_tempfile
# completely untested
my $ext = 'aaa';
do {
# used also in MSWin_temp_cleanup
$spec = catfile(
$tempdir,
sprintf( 'pd%6.6x.%s', time & 0x00ffffff, $ext ),
);
++ $ext;
} while ( -e $spec );
Alternatively, you can try UNLINK => 0 and see if it solves you
immediate problem.
Sorry, I can't investigate this any further without setting up a
DJGPP environment.
Sinan
--
A. Sinan Unur <1usa AT llenroc DOT ude DOT invalid>
(remove .invalid and reverse each component for email address)
comp.lang.perl.misc guidelines on the WWW:
http://www.rehabitation.com/clpmisc/
- Raw text -