Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine

Re^5: What is the preferred cross-platform IPC module?

by BrowserUk (Pope)
on May 15, 2012 at 16:28 UTC ( #970680=note: print w/replies, xml ) Need Help??

in reply to Re^4: What is the preferred cross-platform IPC module?
in thread What is the preferred cross-platform IPC module?

Sorry, for trying to help.

My experiences of using IPC::Run on windows are dire. It is an over-engineered behemoth of a module that attempts to use *nix techniques to provide *nix capabilities on Windows, and fails dismally.

The point about winopen2 is that it provides you with a pair of selectable handles connected to the child process' STDIN & STDOUT.

As such, it is 'compatibile' with *nix-style code written using IPC::Open2 and select.

Ie. you'd only need do something like:

my( $in, $out ); if( $^O eq 'MSWin32' ) { ($in, $out ) = winopen2( $theCommand ); } else { open2( $in, $out, $theCommand ); } ... select .....

But, its not in a module so ...

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

The start of some sanity?

Replies are listed 'Best First'.
Re^6: What is the preferred cross-platform IPC module?
by Theory (Beadle) on May 15, 2012 at 19:56 UTC

    I appreciate the help. That doesn't look bad, but then what does one do about error handling? Can errors from the child caught? At exec time? After that? That's what I imagine a module would take care of.

    I agree about IPC::Run. I am just surprised that there isn't a decent solution to this problem. Must come up all the bloody time…

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://970680]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2018-04-19 23:34 GMT
Find Nodes?
    Voting Booth?