Click here to get back home

Anyone using IPC::Cmd on Windows?

 HomeNewsGroups | Search | About
 comp.lang.perl.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Anyone using IPC::Cmd on Windows? Ronny 05-05-2008
Posted by Ronny on May 5, 2008, 8:39 am
Please log in for more thread options
I'm using ActiveState Perl 5.10.0 for Windows, and wanted to use
IPC::Cmd for running external programs. To my surprise, I found

IPC::Cmd->can_capture_buffer

returning false, meaning that I can't use it to capture the output of
the programs. Also, I found

IPC::Cmd->can_use_ipc_run

returning false, but

IPC::Cmd->can_use_ipc_open3

returning true. Does anybody know about a Perl implementation for
Windows where these features are implemented? Can the
ActiveState implementation of IPC::Cmd be used for anything
useful at all under these circumstances?

Ronald

Posted by Ben Morrow on May 5, 2008, 6:28 pm
Please log in for more thread options

> I'm using ActiveState Perl 5.10.0 for Windows, and wanted to use
> IPC::Cmd for running external programs. To my surprise, I found
>
> IPC::Cmd->can_capture_buffer
>
> returning false, meaning that I can't use it to capture the output of
> the programs. Also, I found
>
> IPC::Cmd->can_use_ipc_run
>
> returning false, but
>
> IPC::Cmd->can_use_ipc_open3
>
> returning true. Does anybody know about a Perl implementation for
> Windows where these features are implemented? Can the
> ActiveState implementation of IPC::Cmd be used for anything
> useful at all under these circumstances?

You need to install IPC::Run. You can only capture buffers under Win32
if you can use IPC::Run (and if you're not on Win98), and you can only
use IPC::Run if it's installed. Probably IPC::Cmd ought to depend on
IPC::Run if it's being installed under Win32, since it isn't useful
without it.

(As a hint, all of the above is very clear from the source of the
module. If a module's not doing what you expect, it's always worth at
least glancing at the source, to see if there's some obvious reason.)

Ben

--
You poor take courage, you rich take care:
The Earth was made a common treasury for everyone to share
All things in common, all people one.
'We come in peace'---the order came to cut them down. [ben@morrow.me.uk]

Similar ThreadsPosted
windows program return values vs perl return values from a call to system() -- windows post only October 29, 2005, 6:22 pm
Windows CE, Windows Mobile November 27, 2006, 4:08 pm
Tar on Windows XP January 29, 2007, 5:27 pm
XML-RPC on Windows July 17, 2007, 11:24 am
SSH on windows September 10, 2007, 9:48 pm
Looking for a better shell for windows 2K July 21, 2004, 6:00 pm
run Perl under windows December 25, 2004, 7:07 am
Perl on Windows January 21, 2005, 12:43 pm
PAR/PP on Windows XP with ActiveState February 3, 2005, 6:30 am
Windows Clipboard April 29, 2005, 10:10 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap