Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^2: File::Temp throwing errors after installation of a module

by Anonymous Monk
on Feb 12, 2019 at 22:14 UTC ( [id://1229849]=note: print w/replies, xml ) Need Help??


in reply to Re: File::Temp throwing errors after installation of a module
in thread File::Temp throwing errors after installation of a module

Thank you for the response! Our current Perl version is 5.10.1, File::Temp's version is 0.22. Could you please elaborate what you mean by removing the offending function names from the list?
  • Comment on Re^2: File::Temp throwing errors after installation of a module

Replies are listed 'Best First'.
Re^3: File::Temp throwing errors after installation of a module
by syphilis (Archbishop) on Feb 13, 2019 at 00:45 UTC
    Could you please elaborate what you mean by removing the offending function names from the list?

    Remove the "NOINHERIT" from the line:
    for my $oflag (qw/ NOFOLLOW BINARY LARGEFILE NOINHERIT /) {
    Also, remove entirely (or comment out):
    # Special case O_EXLOCK $LOCKFLAG = eval { local $SIG{__DIE__} = sub {}; local $SIG{__WARN__} = sub {}; &Fcntl::O_EXLOCK(); };
    And remove entirely (or comment out):
    unless ($^O eq 'MacOS') { for my $oflag (qw/ TEMPORARY /) { my ($bit, $func) = (0, "Fcntl::O_" . $oflag); local($@); no strict 'refs'; $OPENTEMPFLAGS |= $bit if eval { # Make sure that redefined die handlers do not cause problems # e.g. CGI::Carp local $SIG{__DIE__} = sub {}; local $SIG{__WARN__} = sub {}; $bit = &$func(); 1; }; } }
    What does the following output:
    perl -le print $^O
    File::Temp clearly expects that, unless $^O is 'MacOS', then the Fcntl module will provide the O_NOINHERIT, O_EXLOCK and O_TEMPORARY macros.
    Possibilities are:
    1) That the Fcntl module is not constructed correctly;
    2) that $^O is set incorrectly;
    3) that the condition "unless ($^O eq 'MacOS')" needs to be modified.

    What version of Fcntl do you have ?
    Like you, on my perl-5.10 (windows), I have version 0.22 of File::Temp - and I have version 1.06 of Fcntl.

    Updating to a more recent version of perl (say 5.28.x) may well fix the problem, though what you're experiencing is very strange and I'm loath to blame it on the age of your perl-5.10.1.

    Cheers,
    Rob

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1229849]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (3)
As of 2024-04-25 09:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found