rgren925 has asked for the wisdom of the Perl Monks concerning the following question:
Is there a way to test, up front, if the program I'm calling was compiled for the this platform? I'd like to just skip the program call if I can tell it won't work
The call returns a -1, but still throws the error. I tried redirecting STDERR to /dev/null, but then I no longer receive the -1.Code:
Thanks very much, Rick$text = `$command 2> /dev/null`; $retCode = $?;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Calling a binary from a different platform
by roboticus (Chancellor) on Oct 28, 2014 at 00:13 UTC | |
|
Re: Calling a binary from a different platform
by Laurent_R (Canon) on Oct 27, 2014 at 20:00 UTC | |
by rgren925 (Beadle) on Oct 27, 2014 at 21:52 UTC | |
|
Re: Calling a binary from a different platform
by Mr. Muskrat (Canon) on Oct 28, 2014 at 17:21 UTC |