[win32] fix build with MinGW

follow 9318cba347635120cf08004b1f457cc3
[pbc_to_exe] fix build with MinGW
[win32] improve the pbc_to_exe fix

and next time please check the smoke-me branch at first, which already included
those fixes (and more)
[win32] improve cast of arg 3 to CryptGenRandom to BYTE*

ChangeLog for wrong Parrot_{g,s,uns}etenv declarations on windows.
Closes #1156