automake: add configuration for mingw64 and msys/msys2