Confirmed that the call to Cwd::getcwd() in write_buildcustomize.pl returns undef, causing the subsequent calls to miniperl to fail.