This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author cgohlke
Recipients cgohlke, larry, lemburg, paul.moore, steve.dower, tim.golden, zach.ware
Date 2015-09-03.02:16:09
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1441246571.09.0.361271030949.issue24872@psf.upfronthosting.co.za>
In-reply-to
Content
I have now recompiled hundreds of Python packages and C/C++/Fortran libraries with the `/MT /GL /LTCG /NODEFAULTLIB:libucrt.lib ucrt.lib` flags. Many packages test OK, only few crashes.

Some more findings:

The /MT flag forces to also statically link the Intel Fortran runtime library.

Some libraries, e.g. OpenCV and Boost DLLs, can not be built with those flags (must be /MD).

Although most packages pass unittests (numpy, scipy, matplotlib, etc.), running real world scripts, Pandas unit tests, or simple scripts in IPython notebook, fail semi-randomly with "ImportError: DLL load failed: A dynamic link library (DLL) initialization routine failed". This is reproducible with Python 3.5.0rc2, 64 and 32 bit, on Windows 10 and 7, 64 bit. It seems to be related to the number of extensions and DLLs loaded into the process. This needs more testing. Is there still a limit of how many DLLs, which are statically-linked to the CRT, can be loaded?
<https://support.microsoft.com/en-us/kb/193462>
<http://stackoverflow.com/questions/1437422>
<https://social.msdn.microsoft.com/Forums/windowsdesktop/en-US/3546c3c4-1b36-4552-85c5-1b3ba860ee84>
History
Date User Action Args
2015-09-03 02:16:11cgohlkesetrecipients: + cgohlke, lemburg, paul.moore, larry, tim.golden, zach.ware, steve.dower
2015-09-03 02:16:11cgohlkesetmessageid: <1441246571.09.0.361271030949.issue24872@psf.upfronthosting.co.za>
2015-09-03 02:16:11cgohlkelinkissue24872 messages
2015-09-03 02:16:09cgohlkecreate