File 0003-Use-static-zlilb-to-avoid-the-requirement-of-setting.patch of Package mingw64-python3
From 3d8f4955639ae0026efd2ce87c2297db7b1afaa3 Mon Sep 17 00:00:00 2001
From: Ralf Habacker <ralf.habacker@freenet.de>
Date: Sun, 16 Oct 2022 19:52:36 +0200
Subject: [PATCH] Use static zlib to avoid the requirement of setting shared
library path; add required import library for _set_abort_behavior
---
cmake/libpython/CMakeLists.txt | 3 +++
1 file changed, 3 insertions(+)
diff --git a/cmake/libpython/CMakeLists.txt b/cmake/libpython/CMakeLists.txt
index 40d32f8..5ba3e5a 100644
--- a/cmake/libpython/CMakeLists.txt
+++ b/cmake/libpython/CMakeLists.txt
@@ -463,6 +463,9 @@ add_executable(_freeze_importlib
${LIBPYTHON_OMIT_FROZEN_SOURCES}
)
target_link_libraries(_freeze_importlib ${LIBPYTHON_TARGET_LIBRARIES})
+if(WIN32)
+ target_link_libraries(_freeze_importlib libz.a msvcr100)
+endif()
if(builtin_compile_definitions_without_py_limited_api)
target_compile_definitions(_freeze_importlib PUBLIC ${builtin_compile_definitions_without_py_limited_api})
endif()
--
2.34.1