Well I've got my own answer, I don't know if you've figured this out yet but I might as well post the solution for anyone else running into this.
You have to run the Perl program from Qshell! You can start an interactive session in Qshell with the QSH command, or run the program with this type of command:
QSH CMD('/QSYS.LIB/PERLDIST.LIB/PERL.PGM /tmp/hello.pl')
Qshell will take care of setting up the descriptors and environment variables for you. So a command run by Qshell can assume that descriptors 0, 1, and 2 are available for stdin, stdout, and stderr.
Steve