Files
MINGW-packages/mingw-w64-python-pywin32/010-workaround-broken-add-dll-dir.patch
Christoph Reiter 6a7f250c84 pywin32: workaround broken os.add_dll_directory
Disable it, so it takes the fallback path used for older Python
versions.

Fixes #9751
2021-10-10 22:10:30 +02:00

13 lines
722 B
Diff

--- pywin32-b301/win32/Lib/pywin32_bootstrap.py.orig 2021-10-10 22:06:51.034000000 +0200
+++ pywin32-b301/win32/Lib/pywin32_bootstrap.py 2021-10-10 22:07:34.878519800 +0200
@@ -18,7 +18,8 @@
# https://docs.python.org/3/reference/import.html#__path__
for path in pywin32_system32.__path__:
if os.path.isdir(path):
- if hasattr(os, "add_dll_directory"):
+ # XXX: https://github.com/msys2-contrib/cpython-mingw/issues/48
+ if 0 and hasattr(os, "add_dll_directory"):
os.add_dll_directory(path)
# This is to ensure the pywin32 path is in the beginning to find the
# pywin32 DLLs first and prevent other PATH entries to shadow them