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

Expose zlib constants for backwards compat #747 #750

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

brad0
Copy link
Contributor

@brad0 brad0 commented Dec 16, 2023

Building a project that had an internal copy of minizip 1.x, but
preferring an external library, with minizip 4.x showed that the
compat layer was not exposing some constants from zlib that
minizip 1.x headers did.

@brad0 brad0 marked this pull request as draft December 17, 2023 03:51
mz_compat_shim.h.in Outdated Show resolved Hide resolved
mz_compat.h Show resolved Hide resolved
@nmoinvaz
Copy link
Member

nmoinvaz commented Dec 18, 2023

From the CI:

D:\a\minizip-ng\minizip-ng\mz_compat.h(19,10): fatal  error C1083: Cannot open include file: 'zlib.h': 
No such file or directory [D:\a\minizip-ng\minizip-ng\test\gtest_minizip.vcxproj]

@nmoinvaz
Copy link
Member

nmoinvaz commented Dec 18, 2023

I could be wrong, but I think this CMake:

minizip-ng/CMakeLists.txt

Lines 713 to 714 in ef3ef9a

target_include_directories(${MINIZIP_TARGET} PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>)

needs to add ${ZLIB_SOURCE_DIR} and ${ZLIB_BINARY_DIR}.

@nmoinvaz
Copy link
Member

Should I wait on this PR to make a new release?

Building a project that had an internal copy of minizip 1.x, but
preferring an external library, with minizip 4.x showed that the
compat layer was not exposing some constants from zlib that
minizip 1.x headers did.
@brad0
Copy link
Contributor Author

brad0 commented Dec 22, 2023

Should I wait on this PR to make a new release?

Go for 4.0.4.

@Neustradamus
Copy link

For information, minizip-ng 4.0.7 has been released (2024-06-15).

Comment on lines +714 to +716
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>
${ZLIB_SOURCE_DIR}
${ZLIB_BINARY_DIR})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From my experiments, that part isn't needed. It's actually causing extra build issues (for Windows).

I came up with a solution that builds in #815

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants