[Python-Dev] [Windows] how to prevent the wrong version of zlib1.dll to be used by lib-dynload modules

Eric Le Lay contact at elelay.fr
Mon Jul 23 10:31:12 EDT 2018

Hello list,

I encountered a problem with the Windows packaging of gPodder[1]
using msys2:

basic libraries (zlib, openssl) depended upon by python
platform-specific modules are loaded preferably :
 1. from lib-dynload (where they are not)
 2. from the Windows directory (can be any version)
 3. from the binary directory, next to gpodder.exe (where they are)

So an old zlib1.dll installed by another application in c:\Windows was
loaded, incompatible with libpng and gPodder couldn't start.

I don't know what's the best approach to solve it:
 - copy those libraries to lib\pythonxx\lib-dynload (works)
 - preload them in my main script before they are loaded by the module
 - patch something in python (dynload_win.c ?) to search first in the
   executable directory (not tried)

Please can you provide me with insight on this?

Details in the issue: [1]


[1] https://github.com/gpodder/gpodder/issues/478
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: Signature digitale OpenPGP
URL: <http://mail.python.org/pipermail/python-dev/attachments/20180723/421da9e9/attachment.sig>

More information about the Python-Dev mailing list