cloudbase / PyMI

A blazing fast replacement for the Python WMI module
Apache License 2.0
21 stars 14 forks source link

Statically link the VC runtime #46

Closed petrutlucian94 closed 4 years ago

petrutlucian94 commented 4 years ago

Before switching to distutils, we were statically linking the VC runtime.

distutils, on the other hand, is enforcing dynamic linking. The reason is that some extensions were hitting some runtime limitations when statically linking it: https://bugs.python.org/issue38597

This admittedly hacky patch will override the hardcoded distutils /MD flag. It should work with all the supported Python versions. For future versions, we're probably going to request the Python community a better way of statically linking the runtime when aware of the limitations.