[zlib] Update to 1.3.2#51235
Conversation
- Static builds - Non-windows builds - Include path for debug builds in pkgconfig
Irrelevant of the actual configuration for shared and/or static compilation, ZLIBConfig.cmake always assumes that both are available.
This reverts commit 52bc54a.
|
Thank you so much! I'm sorry that the arm64-linux configuration has been such a thorn in everyone's side. This time it looks like it might be legitimate though :( |
I think it is a race, and I will just run CI again. |
The ffmpeg situation ( which even without concurrency produces The secondary output ( A fix might apply the approach chosen for the |
|
All checks have passed. Use it or loose it. |
|
@dg0yt: Thanks for your work and thanks to @BillyONeal for merging! It fixes the CVE-2026-27171: Linked to: |
|
This breaks ports that depend on For me this breaks my vendored sdl3_image, since they set it if undefined. I am working around this by setting it to OFF, but this worked before as is. It is possible this breaks other triplets too, but this is the only one I use. |
|
Upstream made a patch release which fixes a CVE, introduces signifcant CMake changes, and renames binaries. "This" PR updated the port and adjusted downstream ports as needed. Including removing some usage of If unhappy with upstream's choices, please go there and report. |
| ${COMMON_OPTIONS} | ||
| -DDLIB_PNG_SUPPORT=ON | ||
| -DCMAKE_REQUIRE_FIND_PACKAGE_PNG=ON | ||
| -Dtest_for_libpng_worked=TRUE # try_compile ignores vcpkg setup |
There was a problem hiding this comment.
Why? try_compile should see the toolchain and variables should be passed through.
There was a problem hiding this comment.
Maybe it doesn't describe the problem correctly.
Unfortunately I cannot reproduce it now, but there are CI logs where the try_compile test failed for some triplets, e.g. x64-windows-static:
FAILED: [code=2] CMakeFiles/libpng_test.dir/libpng_test.cpp.obj
C:\\PROGRA~1\\MICROS~1\\2022\\ENTERP~1\\VC\\Tools\\MSVC\\1444~1.352\\bin\\Hostx64\\x64\\cl.exe /nologo /TP /DWIN32 /D_WINDOWS /W3 /GR /EHsc /MDd /Zi /Ob0 /Od /RTC1 /showIncludes /FoCMakeFiles\\libpng_test.dir\\libpng_test.cpp.obj /FdCMakeFiles\\libpng_test.dir\\ /FS -c D:\\b\\dlib\\src\\v20.0.1-f170b8e716.clean\\dlib\\cmake_utils\\test_for_libpng\\libpng_test.cpp
D:\\b\\dlib\\src\\v20.0.1-f170b8e716.clean\\dlib\\cmake_utils\\test_for_libpng\\libpng_test.cpp(3): fatal error C1083: Cannot open include file: 'png.h': No such file or directory
I couldn't spot the root cause in reasonable time for the zlib update. But I came to the conclusion that this test didn't add value: We know that libpng works. (And we could react if the build fails later.) I left the comment to catch the eye of the right person.
FTR these try_compile tests are broken: The CMAKE_FLAGS aren't passed correctly. Everything lands in CMAKE_PREFIX_PATH. Too many quotes here:
https://github.com/davisking/dlib/blob/3d40bf5790ca9073c160cebb898800d9f33e12ab/dlib/cmake_utils/find_libpng.cmake#L20-L29
|
I confirm that this breaks projects depending on ZLIB on Windows: See those logs. |
This does not go through the |
…51235 Drop the REQUIRED + VCPKG_BUILD_TYPE gating in favour of the broader name set used in the upstream vcpkg fix (which also handles the static linkage 'zs.lib' / 'zsd.lib' produced by the new zlib 1.3.2 port). release: z zs zlib debug: zd zsd zlibd Ref: microsoft/vcpkg#51235
vcpkg's zlib port is being updated to 1.3.2 (microsoft/vcpkg PR #51235), whose CMake build sets OUTPUT_NAME=z (shared) / zs (static) on MSVC, so the import library is no longer named zlib.lib / zlibd.lib. The python3 portfile's find_library(NAMES zlib ...) silently returned ZLIB_RELEASE-NOTFOUND, which was passed verbatim into vcpkg_msbuild_install(ADDITIONAL_LIBS_RELEASE ...) and ultimately to link.exe as 'ZLIB_RELEASE-NOTFOUND.obj', producing an opaque LNK1181 error deep in CPython's PCbuild. Mirror microsoft/vcpkg#51235's exact name set so this port stays consistent with the upstream zlib bump: release: z zs zlib debug: zd zsd zlibd
…51235 Drop the REQUIRED + VCPKG_BUILD_TYPE gating in favour of the broader name set used in the upstream vcpkg fix (which also handles the static linkage 'zs.lib' / 'zsd.lib' produced by the new zlib 1.3.2 port). release: z zs zlib debug: zd zsd zlibd Ref: microsoft/vcpkg#51235
* Bump vcpkg baselines
* error report when building with vcpkg
* handle case when there is no artifact
* do not rely on /tmp
* fix encoding
* link to error log echoed in workflow
* add python overlay to test zlib detection
* [python3 overlay] Skip ZLIB_DEBUG lookup on release-only triplets
VCPKG_BUILD_TYPE=release triplets (e.g. x64-windows-release) don't install debug libs, so find_library(ZLIB_DEBUG ... REQUIRED) fails fatally even though add_libs_dbg is unused in release-only builds. Gate the debug lookup on the build type.
* vcpkg_build_failures_report: surface portfile-execute aborts
Two related fixes for the case where vcpkg fails before any port leaves a parseable buildtree (e.g. a CMake Error in portfile.cmake from find_library REQUIRED, or vcpkg_extract_source_archive download failure). Previously the parser saw nothing and the report claimed 'all ports built ✅' despite a non-zero exit code.
1. parse_failures.py: new --manifest-install-log option that scans vcpkg-manifest-install.log for 'error: building <port>:<triplet> failed with: BUILD_FAILED' lines and 'CMake Error at .../ports/<port>/portfile.cmake' blocks, synthesizing failure records (with excerpts) for ports that never produced a buildtree.
2. format_report.py + action.yml: new build-status input. When the upstream build/configure step failed but no per-port failures were parsed, render a 'vcpkg failed before producing per-port logs' banner with links to the artifacts/run instead of the misleading 'all ports built' line.
Both windows-qt6.yml and build-macos-qt6.yml now pass build-status=${{ job.status }} and manifest-install-log=${{ github.workspace }}/build/vcpkg-manifest-install.log.
* [python3 overlay] Align ZLIB find_library names with microsoft/vcpkg#51235
Drop the REQUIRED + VCPKG_BUILD_TYPE gating in favour of the broader name set used in the upstream vcpkg fix (which also handles the static linkage 'zs.lib' / 'zsd.lib' produced by the new zlib 1.3.2 port).
release: z zs zlib
debug: zd zsd zlibd
Ref: microsoft/vcpkg#51235
* vcpkg_build_failures_report: escape ${{ in build-status description
GitHub evaluates ${{ ... }} expressions inside input descriptions too, so the previous wording caused the composite action to fail to load with 'Unrecognized named-value: job'. Rephrase the description to avoid the expression syntax.
Fixes the action.yml validation error seen in workflow run 69945800777.
* [py-psycopg-c] Fix pg_config path on non-Windows
libpq's portfile uses vcpkg_copy_tools(TOOL_NAMES pg_config ...) without a DESTINATION, so the binary lands at tools/libpq/pg_config — not tools/libpq/bin/pg_config. The else() branch of py-psycopg-c had the wrong path, causing the build to fall back to PATH lookup of pg_config (not present) and fail with 'No such file or directory'. Match the Windows branch which already uses tools/libpq with no /bin.
Failure seen on arm64-osx-dynamic-release / x64-osx-dynamic-release in workflow run 69945800777.
* vcpkg overlays: drop libxml2 and py-psycopg-c (fixed upstream)
Both fixes have landed in their respective upstream registries (microsoft/vcpkg for libxml2, open-vcpkg/python-registry for py-psycopg-c). The overlay copies are no longer needed.
* vcpkg: bump python-registry baseline to 17723c4
Pulls in py-psycopg-c 3.3.4#3 (pg_config path fix) and other recent updates from open-vcpkg/python-registry.
* vcpkg_build_failures_report: surface commit SHA in sticky comment
Adds an optional commit-sha input. When set, the rendered report footer shows a linked short SHA (e.g. 📌 Commit `abc1234`) so reviewers know which revision the sticky comment reflects.
Wired up the windows-qt6 and build-macos-qt6 workflows to pass github.event.pull_request.head.sha (with fallback to github.sha).
* remove python overlay
* Restore libxml2 overlay (dropped prematurely)
* bump python-reg
* vcpkg: bump python-registry baseline to 1578c39
Integrates open-vcpkg/python-registry#240 ([py-psycopg-c] Make it usable without pg_config) which fixes the pg_config path issue on non-Windows post-meson refactor of microsoft/vcpkg's libpq port.
* bump pr
* Update vcpkg.json
* Update vcpkg.json
* Update vcpkg.json
* Update vcpkg.json
* Update vcpkg.json
* Update vcpkg.json
---------
Co-authored-by: 3nids <127259+3nids@users.noreply.github.com>
Continued from #50538 by @scschaefer.
Resolves #50060.
Closes #50843.
Downstream fixes as needed:
ZLIB_LIBRARIES,crc32with port elfutils.(The symbol was already there, maybe the signature changed a little bit. I don't know why it didn't occur earlier.)
serf got a little bit more work, to ensure that all three deps are handled in a consistent way and to not mix debug and release paths.
qt5-base[postgresqlplugin](windows & !static) was probably already broken with libpq 18.3 - it is not in the cone of destruction for libpq. It should be reviewed and tested with the fixes to libpq (separate PR).