From 00c88a940c59a804e53e16ac2ae703a35aef1bd2 Mon Sep 17 00:00:00 2001 From: Agel Date: Sun, 25 Oct 2026 21:41:24 +0100 Subject: [PATCH] windows build fix --- AGENTS.md | 2 +- CMakeLists.txt | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 9edcb9a..30ab519 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -51,7 +51,7 @@ Full target format list: ### Dependencies - Qt 6.10+ components: `Core`, `Gui`, `Qml`, `Quick`, `Widgets`, `Concurrent`, `Svg`, `QuickControls2`, `Test`, `Xml`, `Network`, optional `DBus`. -- Third-party packages: `minizip`, `libarchive`. +- Third-party packages: `minizip`, `libarchive`, `iconv`. - Graphics API: Vulkan (Windows, Linux), Metal (macOS) configured via `QQuickWindow::setGraphicsApi()`. ### Windows Build Environment diff --git a/CMakeLists.txt b/CMakeLists.txt index a520e1e..f284973 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,13 +25,14 @@ find_package(Qt6 OPTIONAL_COMPONENTS DBus) # Third-party libraries find_package(PkgConfig REQUIRED) +find_package(Iconv REQUIRED) pkg_check_modules(MINIZIP REQUIRED IMPORTED_TARGET minizip) pkg_check_modules(LIBARCHIVE REQUIRED IMPORTED_TARGET libarchive) # libarchive on Windows is built with CNG enabled (BCryptGenRandom for temp files). -# bcrypt.lib is not listed in the .pc file, so inject it here. +# bcrypt.lib and iconv are not listed in the .pc file, so inject them here. if(WIN32) set_property(TARGET PkgConfig::LIBARCHIVE APPEND PROPERTY - INTERFACE_LINK_LIBRARIES bcrypt) + INTERFACE_LINK_LIBRARIES bcrypt Iconv::Iconv) endif() # Source files