diff --git a/recipes/minizip/all/conanfile.py b/recipes/minizip/all/conanfile.py index f775fd9f5b915..2f0791217e9ca 100644 --- a/recipes/minizip/all/conanfile.py +++ b/recipes/minizip/all/conanfile.py @@ -68,6 +68,11 @@ def generate(self): tc.variables["MINIZIP_SRC_DIR"] = os.path.join(self.source_folder, "contrib", "minizip").replace("\\", "/") tc.variables["MINIZIP_ENABLE_BZIP2"] = self.options.bzip2 tc.variables["MINIZIP_BUILD_TOOLS"] = self.options.tools + + # fopen64 and similar are unavailable before API level 24: https://github.com/madler/zlib/pull/436 + if self.settings.os == "Android" and int(str(self.settings.os.api_level)) < 24: + tc.preprocessor_definitions["IOAPI_NO_64"] = "1" + tc.generate() deps = CMakeDeps(self) deps.generate()