From 3bced613bc164e4ec445abc6d86d6aa3e218a476 Mon Sep 17 00:00:00 2001 From: Nathan Moinvaziri Date: Mon, 11 Nov 2024 10:56:18 -0800 Subject: [PATCH] Move zlib include to zip/unzip headers like org minizip. --- compat/ioapi.h | 8 -------- compat/unzip.h | 8 ++++++++ compat/zip.h | 8 ++++++++ 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/compat/ioapi.h b/compat/ioapi.h index 82507460..6cdfc3f0 100644 --- a/compat/ioapi.h +++ b/compat/ioapi.h @@ -4,14 +4,6 @@ #include -#if !defined(_ZLIB_H) && !defined(ZLIB_H) && !defined(ZLIB_H_) -# if __has_include() -# include -# elif __has_include() -# include -# endif -#endif - typedef uint64_t ZPOS64_T; #ifndef ZEXPORT diff --git a/compat/unzip.h b/compat/unzip.h index 0c081542..07718f88 100644 --- a/compat/unzip.h +++ b/compat/unzip.h @@ -19,6 +19,14 @@ extern "C" { #include +#if !defined(_ZLIB_H) && !defined(ZLIB_H) && !defined(ZLIB_H_) +# if __has_include() +# include +# elif __has_include() +# include +# endif +#endif + #ifndef _ZLIBIOAPI_H # include "ioapi.h" #endif diff --git a/compat/zip.h b/compat/zip.h index 67f5a5b1..fa7785ce 100644 --- a/compat/zip.h +++ b/compat/zip.h @@ -19,6 +19,14 @@ extern "C" { #include +#if !defined(_ZLIB_H) && !defined(ZLIB_H) && !defined(ZLIB_H_) +# if __has_include() +# include +# elif __has_include() +# include +# endif +#endif + #ifndef _ZLIBIOAPI_H # include "ioapi.h" #endif