% perl -e 'open(F,"./asdf 2>&1|");while($x=){print "Captured $x";}' Captured output to stdout Captured output to stderr