Fix build with minizip-ng 4.0.8

This commit is contained in:
Joshua Vandaële 2025-01-11 12:19:37 +01:00
parent 3ea870ef8c
commit fa442dc90b
No known key found for this signature in database
GPG Key ID: 5E8F4E7EDBD390EA
6 changed files with 19 additions and 9 deletions

View File

@ -2,8 +2,13 @@ project(minizip C)
add_library(minizip STATIC add_library(minizip STATIC
minizip-ng/mz.h minizip-ng/mz.h
minizip-ng/mz_compat.c # minizip-ng/compat/crypt.h
minizip-ng/mz_compat.h minizip-ng/compat/ioapi.c
minizip-ng/compat/ioapi.h
minizip-ng/compat/unzip.c
minizip-ng/compat/unzip.h
# minizip-ng/compat/zip.c
# minizip-ng/compat/zip.h
minizip-ng/mz_crypt.c minizip-ng/mz_crypt.c
minizip-ng/mz_crypt.h minizip-ng/mz_crypt.h
minizip-ng/mz_os.c minizip-ng/mz_os.c
@ -60,7 +65,7 @@ endif()
# minizip-ng/mz_crypt_winvista.c # minizip-ng/mz_crypt_winvista.c
# minizip-ng/mz_crypt_winxp.c # minizip-ng/mz_crypt_winxp.c
target_include_directories(minizip PUBLIC minizip-ng) target_include_directories(minizip PUBLIC minizip-ng minizip-ng/compat)
target_compile_definitions(minizip PRIVATE HAVE_ZLIB ZLIB_COMPAT MZ_ZIP_NO_CRYPTO MZ_ZIP_NO_ENCRYPTION) target_compile_definitions(minizip PRIVATE HAVE_ZLIB ZLIB_COMPAT MZ_ZIP_NO_CRYPTO MZ_ZIP_NO_ENCRYPTION)
if (UNIX) if (UNIX)

@ -1 +1 @@
Subproject commit 3eed562ef0ea3516db30d1c8ecb0e1b486d8cb70 Subproject commit 55db144e03027b43263e5ebcb599bf0878ba58de

View File

@ -17,11 +17,14 @@
<PropertyGroup Label="UserMacros" /> <PropertyGroup Label="UserMacros" />
<ItemDefinitionGroup> <ItemDefinitionGroup>
<ClCompile> <ClCompile>
<!-- Ensure minizip-ng sees mz.h -->
<AdditionalIncludeDirectories>minizip-ng;minizip-ng\compat;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>HAVE_ZLIB;ZLIB_COMPAT;MZ_ZIP_NO_CRYPTO;MZ_ZIP_NO_ENCRYPTION;HAVE_STDINT_H;HAVE_INTTYPES_H;NO_FSEEKO;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>HAVE_ZLIB;ZLIB_COMPAT;MZ_ZIP_NO_CRYPTO;MZ_ZIP_NO_ENCRYPTION;HAVE_STDINT_H;HAVE_INTTYPES_H;NO_FSEEKO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile> </ClCompile>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="minizip-ng\mz_compat.c" /> <ClCompile Include="minizip-ng\compat\ioapi.c" />
<ClCompile Include="minizip-ng\compat\unzip.c" />
<ClCompile Include="minizip-ng\mz_crypt.c" /> <ClCompile Include="minizip-ng\mz_crypt.c" />
<ClCompile Include="minizip-ng\mz_os.c" /> <ClCompile Include="minizip-ng\mz_os.c" />
<ClCompile Include="minizip-ng\mz_os_win32.c" /> <ClCompile Include="minizip-ng\mz_os_win32.c" />
@ -36,7 +39,8 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="minizip-ng\mz.h" /> <ClInclude Include="minizip-ng\mz.h" />
<ClInclude Include="minizip-ng\mz_compat.h" /> <ClCompile Include="minizip-ng\compat\ioapi.h" />
<ClCompile Include="minizip-ng\compat\unzip.h" />
<ClInclude Include="minizip-ng\mz_crypt.h" /> <ClInclude Include="minizip-ng\mz_crypt.h" />
<ClInclude Include="minizip-ng\mz_os.h" /> <ClInclude Include="minizip-ng\mz_os.h" />
<ClInclude Include="minizip-ng\mz_strm.h" /> <ClInclude Include="minizip-ng\mz_strm.h" />

View File

@ -5,7 +5,7 @@
#include <algorithm> #include <algorithm>
#include <mz_compat.h> #include <unzip.h>
#include "Common/CommonTypes.h" #include "Common/CommonTypes.h"
#include "Common/ScopeGuard.h" #include "Common/ScopeGuard.h"

View File

@ -13,8 +13,8 @@
#include <unordered_set> #include <unordered_set>
#include <mbedtls/md5.h> #include <mbedtls/md5.h>
#include <mz_compat.h>
#include <pugixml.hpp> #include <pugixml.hpp>
#include <unzip.h>
#include "Common/Align.h" #include "Common/Align.h"
#include "Common/Assert.h" #include "Common/Assert.h"

View File

@ -6,8 +6,9 @@
#include <algorithm> #include <algorithm>
#include <memory> #include <memory>
#include <mz_compat.h> #include <mz.h>
#include <mz_os.h> #include <mz_os.h>
#include <unzip.h>
#include "Common/CommonPaths.h" #include "Common/CommonPaths.h"
#include "Common/Contains.h" #include "Common/Contains.h"