From: Adrien Gallouët Date: Wed, 3 Dec 2025 13:47:02 +0000 (+0100) Subject: cmake: explicitly link against crypt32 on non-MSVC Windows builds (#17727) X-Git-Tag: upstream/0.0.7446~194 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=083e18b11c24fff9e306801cd6f226eecbbb225c;p=pkg%2Fggml%2Fsources%2Fllama.cpp cmake: explicitly link against crypt32 on non-MSVC Windows builds (#17727) Some toolchains do not support linking via pragmas such as: #pragma comment(lib, "crypt32.lib") so we need to add the library explicitly. Signed-off-by: Adrien Gallouët --- diff --git a/vendor/cpp-httplib/CMakeLists.txt b/vendor/cpp-httplib/CMakeLists.txt index 8e1cd9a9..369502d7 100644 --- a/vendor/cpp-httplib/CMakeLists.txt +++ b/vendor/cpp-httplib/CMakeLists.txt @@ -144,4 +144,7 @@ if (CPPHTTPLIB_OPENSSL_SUPPORT) find_library(SECURITY_FRAMEWORK Security REQUIRED) target_link_libraries(${TARGET} PUBLIC ${CORE_FOUNDATION_FRAMEWORK} ${SECURITY_FRAMEWORK}) endif() + if (WIN32 AND NOT MSVC) + target_link_libraries(${TARGET} PUBLIC crypt32) + endif() endif()