in reply to Problem invoking Matlab from Perl: works on Linux, fails on Windows

Your first "replacement":
$sts = system($matlab_cmd_str);
should work like you want it to on a win32 system. The system command has to be told specifically to return before the command completes, and you do not do that here.