commit patch for compiling on mingw32