Resolve issues on Mingw.