Tweaks for cross compiling from Cygwin to MinGW

* Cygwin versions of MinGW compilers put standard libraries in /bin, not /lib
* Blas and Lapack should be in build_shlibdir
* Don't use wine for Cygwin to MinGW cross compile
* New cygpath_w helper function to convert Cygwin paths to Windows-style so MinGW-compiled
executables can understand them
* Use cygpath_w for system image file locations
Merge pull request #5965 from tkelman/cygwin-to-mingw-cross

RFC: Allow Cygwin to MinGW cross compilation