--- configure.ac.orig	2017-02-04 11:31:11.949794798 -0500
+++ configure.ac	2017-02-04 11:31:27.726870712 -0500
@@ -136,7 +136,7 @@
 have_win32="no"
 lt_enable_auto_import=""
 case $host_os in
-mingw*)
+mingw*|*msys*)
         have_win32="yes"
         lt_enable_auto_import="-Wl,--enable-auto-import"
         ;;
@@ -208,7 +208,7 @@
 
 dnl Link with winsock for socket functions on MinGW
 case $host_os in
-        *mingw*)
+        *mingw*|*msys*)
                 AC_CHECK_LIB([ws2_32],[main])
                 ;;
         *)
@@ -256,16 +256,14 @@
 
 AM_CONDITIONAL(XCB_SERVERSIDE_SUPPORT, test "x$XCB_SERVERSIDE_SUPPORT" = "xyes")
 
-AC_CONFIG_FILES([
-Makefile
+AC_CONFIG_FILES([Makefile
 doc/Makefile
 man/Makefile
 src/Makefile
 tests/Makefile
 ])
 
-AC_CONFIG_FILES([
-xcb.pc
+AC_CONFIG_FILES([xcb.pc
 xcb-composite.pc
 xcb-damage.pc
 xcb-dpms.pc
@@ -294,8 +292,7 @@
 xcb-xvmc.pc
 ])
 
-AC_CONFIG_FILES([
-doc/xcb.doxygen
+AC_CONFIG_FILES([doc/xcb.doxygen
 ])
 
 AC_OUTPUT
