my $progPath = cwd(); my $perlPath = $^X; my $args = "-c abc.conf -r"; # then build the command and capture the output... my $output = `\"$perlPath\" \"$progPath/my.pl\" $args`;