Conversation
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
🤖 Augment PR SummarySummary: Updates the vendored zlib dependency from v1.3.1 to v1.3.2. Changes:
Technical Notes: This is largely an upstream vendor refresh; the new zlib release includes API surface expansion and behavior updates that can affect consumers at compile-time (types) and runtime (gzip I/O). 🤖 Was this summary useful? React with 👍 or 👎 |
cmake/FindZLIB.cmake
Outdated
| endif() | ||
|
|
||
| configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zconf.h.cmakein" | ||
| configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zlibConfig.cmake.in" |
There was a problem hiding this comment.
configure_file() is generating ${CMAKE_CURRENT_BINARY_DIR}/zlib/zconf.h from vendor/zlib/zlibConfig.cmake.in, but that input is a CMake package config template (not a zconf.h header template), so the produced/installed zconf.h will be invalid. This also means Z_HAVE_UNISTD_H is no longer reflected in the generated header, which may change platform feature detection for consumers.
Severity: high
🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.
There was a problem hiding this comment.
1 issue found across 27 files
Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="cmake/FindZLIB.cmake">
<violation number="1" location="cmake/FindZLIB.cmake:8">
P1: configure_file now uses zlibConfig.cmake.in to generate zconf.h, which will produce an invalid header and break zlib builds. Use the zconf.h.cmakein template instead.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
cmake/FindZLIB.cmake
Outdated
| endif() | ||
|
|
||
| configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zconf.h.cmakein" | ||
| configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zlibConfig.cmake.in" |
There was a problem hiding this comment.
P1: configure_file now uses zlibConfig.cmake.in to generate zconf.h, which will produce an invalid header and break zlib builds. Use the zconf.h.cmakein template instead.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At cmake/FindZLIB.cmake, line 8:
<comment>configure_file now uses zlibConfig.cmake.in to generate zconf.h, which will produce an invalid header and break zlib builds. Use the zconf.h.cmakein template instead.</comment>
<file context>
@@ -5,7 +5,7 @@ if(NOT ZLIB_FOUND)
endif()
- configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zconf.h.cmakein"
+ configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zlibConfig.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/zlib/zconf.h" @ONLY)
</file context>
| configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zlibConfig.cmake.in" | |
| configure_file("${PROJECT_SOURCE_DIR}/vendor/zlib/zconf.h.cmakein" |
Signed-off-by: Juan Cruz Viotti jv@jviotti.com