--- /dev/null
+--- gzip-1.9/gzip.c 2018-01-07 13:05:21.000000000 +0800
++++ /tmp/gzip.c 2018-07-29 14:37:00.228844928 +0800
+@@ -1910,6 +1910,11 @@
+ return OK;
+ }
+
++#ifdef __MINGW32__
++typedef int uid_t;
++typedef int gid_t;
++#endif
++
+ /* Change the owner and group of a file. FD is a file descriptor for
+ the file and NAME its name. Change it to user UID and to group GID.
+ If UID or GID is -1, though, do not change the corresponding user
+@@ -1917,13 +1922,15 @@
+ static void
+ do_chown (int fd, char const *name, uid_t uid, gid_t gid)
+ {
+-#ifndef NO_CHOWN
++#ifndef __MINGW32__
++#ifndef NO_CHOWN
+ # if HAVE_FCHOWN
+ ignore_value (fchown (fd, uid, gid));
+ # else
+ ignore_value (chown (name, uid, gid));
+ # endif
+ #endif
++#endif
+ }
+
+ /* ========================================================================