Host Environment
To Reproduce
./vcpkg install bzip2:x64-windows-static-release --clean-after-build --overlay-triplets=triplets_overlay
(or any package that depends on bzip2, like qt5-base)
Contents of triplets_overlay/x64-windows-static-release.cmake:
set(VCPKG_TARGET_ARCHITECTURE x64)
set(VCPKG_CRT_LINKAGE static)
set(VCPKG_LIBRARY_LINKAGE static)
set(VCPKG_BUILD_TYPE release)
Failure logs
Starting package 2/16: bzip2:x64-windows-static-release
Building package bzip2[core]:x64-windows-static-release...
Could not locate cached archive: C:\Users\runneradmin\AppData\Local\vcpkg\archives\2c\2c926ea673e5e047cbce2782a0a8d80dcb8aaa26.zip
-- [OVERLAY] Loading triplet configuration from: D:\a\qBittorrent\qBittorrent\triplets_overlay\x64-windows-static-release.cmake
-- Downloading https://github.com/past-due/bzip2-mirror/releases/download/v1.0.6/bzip2-1.0.6.tar.gz...
-- Extracting source C:/qbt_tools/vcpkg/downloads/bzip2-1.0.6.tar.gz
-- Applying patch fix-import-export-macros.patch
-- Applying patch fix-windows-include.patch
-- Using source at C:/qbt_tools/vcpkg/buildtrees/bzip2/src/1.0.6-8838f21f8e.clean
-- Configuring x64-windows-static-release
-- Building x64-windows-static-release-rel
-- Fixing pkgconfig
-- Acquiring MSYS Packages...
-- Acquiring MSYS Packages... OK
-- Fixing pkgconfig - release
-- Checking file: C:/qbt_tools/vcpkg/packages/bzip2_x64-windows-static-release/lib/pkgconfig/bzip2.pc
-- Fixing pkgconfig - debug
-- Checking file: C:/qbt_tools/vcpkg/packages/bzip2_x64-windows-static-release/debug/lib/pkgconfig/bzip2.pc
-- CHECK_LIB_bz2d_DEBUG:CHECK_LIB_bz2d_DEBUG-NOTFOUND
CMake Error at scripts/cmake/vcpkg_fixup_pkgconfig.cmake:239 (message):
Library "bz2d" was not found! If it is a system library use the
SYSTEM_LIBRARIES parameter for the vcpkg_fixup_pkgconfig call! Otherwise,
correct the *.pc file
Call Stack (most recent call first):
scripts/cmake/vcpkg_fixup_pkgconfig.cmake:348 (vcpkg_fixup_pkgconfig_check_files)
ports/bzip2/portfile.cmake:51 (vcpkg_fixup_pkgconfig)
scripts/ports.cmake:79 (include)
Error: Building package bzip2:x64-windows-static-release failed with: BUILD_FAILED
Please ensure you're using the latest portfiles with `.\vcpkg update`, then
submit an issue at https://github.com/Microsoft/vcpkg/issues including:
Package: bzip2:x64-windows-static-release
Vcpkg version: 2020.06.15-nohash
Additionally, attach any relevant sections from the log files above.
Additional context
This is different from https://github.com/microsoft/vcpkg/issues/12689.
Looks like the build process expects to always find stuff related to the debug build, even if just building release (and probably vice-versa).
closed by #12759
What about reopening and merging PR #12772 to fix this issue quickly ?
In my environment #12772 is working just fine, and a similar change was made for pcre in #12629.
Most helpful comment
closed by #12759