Skip to content

python: Port python 3.x module to Windows and improve distutils a bit

Chun-wei Fan requested to merge python3-windows into master

Hi,

This MR attempts to improve Windows support for the libxml2 Python module, by:

  • Supporting Python 3.x for Windows, since previously only *NIX was supported as system-level APIs are needed for Python 3.x.
  • Fix the tstmem.py test script, since libxml2mod may be under libxmlmods.
  • Make DLL packaging in setup.py more flexible: We now use the options that we specified via configure.js or CMake to determine which DLLs we want to pack into the installation or bdist* items, so that we try to avoid excessively packing in DLLs or miss out on required DLLs. Also enable one to change required DLL filenames easier, as different DLLs may be linked in. This is more important for Python 3.8+ where Python requires one to be quite clear on where dependent DLLs are loaded.
  • Import setuptools if found, so that it makes things easier to build wheels.

With blessings, thank you!

Merge request reports