From 13563b7183425878296930bab9c2664cca026a4e Mon Sep 17 00:00:00 2001 From: dbjh Date: Sun, 11 Feb 2024 14:38:44 +0900 Subject: [PATCH 1/2] Fix *64() function issue for MinGW{-w64}. --- zconf.h | 2 +- zconf.h.cmakein | 2 +- zconf.h.in | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/zconf.h b/zconf.h index 62adc8d84..a28322ba8 100644 --- a/zconf.h +++ b/zconf.h @@ -516,7 +516,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t #else -# if defined(_WIN32) && !defined(__GNUC__) +# if defined(_WIN32) && !defined(__CYGWIN__) # define z_off64_t __int64 # else # define z_off64_t z_off_t diff --git a/zconf.h.cmakein b/zconf.h.cmakein index 0abe3bc9d..c1fb757cf 100644 --- a/zconf.h.cmakein +++ b/zconf.h.cmakein @@ -518,7 +518,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t #else -# if defined(_WIN32) && !defined(__GNUC__) +# if defined(_WIN32) && !defined(__CYGWIN__) # define z_off64_t __int64 # else # define z_off64_t z_off_t diff --git a/zconf.h.in b/zconf.h.in index 62adc8d84..a28322ba8 100644 --- a/zconf.h.in +++ b/zconf.h.in @@ -516,7 +516,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t #else -# if defined(_WIN32) && !defined(__GNUC__) +# if defined(_WIN32) && !defined(__CYGWIN__) # define z_off64_t __int64 # else # define z_off64_t z_off_t From 0f56c5aa8997ae5149e4cb480577cc650ad8b379 Mon Sep 17 00:00:00 2001 From: dbjh Date: Tue, 27 Feb 2024 16:41:07 +0900 Subject: [PATCH 2/2] - Proper fix for issue with MinGW{-w64} that is independent of header files. --- zconf.h | 2 +- zconf.h.cmakein | 2 +- zconf.h.in | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/zconf.h b/zconf.h index 04d2b52c8..b0c368c83 100644 --- a/zconf.h +++ b/zconf.h @@ -511,7 +511,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t -#elif defined(_WIN32) && !defined(__CYGWIN__) +#elif defined(_WIN32) || (defined(__GNUC__) && defined(__int64)) # define z_off64_t __int64 #elif defined(__GO32__) # define z_off64_t offset_t diff --git a/zconf.h.cmakein b/zconf.h.cmakein index 2b10d5439..427b64945 100644 --- a/zconf.h.cmakein +++ b/zconf.h.cmakein @@ -513,7 +513,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t -#elif defined(_WIN32) && !defined(__CYGWIN__) +#elif defined(_WIN32) || (defined(__GNUC__) && defined(__int64)) # define z_off64_t __int64 #elif defined(__GO32__) # define z_off64_t offset_t diff --git a/zconf.h.in b/zconf.h.in index 04d2b52c8..b0c368c83 100644 --- a/zconf.h.in +++ b/zconf.h.in @@ -511,7 +511,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t -#elif defined(_WIN32) && !defined(__CYGWIN__) +#elif defined(_WIN32) || (defined(__GNUC__) && defined(__int64)) # define z_off64_t __int64 #elif defined(__GO32__) # define z_off64_t offset_t