Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Externals: Add a stripped down version of minizip #7477

Merged
merged 1 commit into from Nov 17, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -586,6 +586,9 @@ else()
add_subdirectory(Externals/zlib)
endif()

add_subdirectory(Externals/minizip)
include_directories(External/minizip)

if(NOT APPLE)
check_lib(LZO "(no .pc for lzo2)" lzo2 lzo/lzo1x.h QUIET)
endif()
Expand Down
16 changes: 16 additions & 0 deletions Externals/minizip/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
project(minizip C)

set(SRCS ioapi.c unzip.c)

add_definitions(-DNOUNCRYPT)
if(UNIX)
add_definitions(-D__USE_FILE_OFFSET64)
add_definitions(-D__USE_LARGEFILE64)
add_definitions(-D_LARGEFILE64_SOURCE)
add_definitions(-D_FILE_OFFSET_BIT=64)
endif()

add_library(minizip STATIC ${SRCS})
target_include_directories(minizip PUBLIC .)

add_library(MiniZip::minizip ALIAS minizip)
17 changes: 17 additions & 0 deletions Externals/minizip/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Condition of use and distribution are the same as zlib:

This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.

Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:

1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgement in the product documentation would be
appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
2 changes: 2 additions & 0 deletions Externals/minizip/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Partial import from https://github.com/nmoinvaz/minizip
Revision: b3713abe7722f1b779e7cdbd527c6208abbe1121
Loading