Second attempt at this. This is less portable than the previous
version, since it assumes that the target system will have a cat, but unlike
the previous version this now actually works.
# Copy the .c file to the remote host ($to is an ssh-alike if targethost is set)
if $test "X$targethost" != X; then
$to tryp.c
- $run ./tryp \< tryp.c 2>/dev/null > tryp.out
+ $to tryp
+ $run "cat tryp.c | ./tryp" 2>/dev/null > tryp.out
else
$cat tryp.c | $run ./tryp 2>/dev/null > tryp.out
fi
$rm -f tryp.out
if $test "X$targethost" != X; then
$to tryp.c
- $run ./tryp \< tryp.c 2>/dev/null > tryp.out
+ $to tryp
+ $run "cat tryp.c | ./tryp" 2>/dev/null > tryp.out
else
$cat tryp.c | $run ./tryp 2>/dev/null > tryp.out
fi