[Numpy-discussion] Is anyone knowledgeable about dll deployment on windows ?

David Cournapeau david at ar.media.kyoto-u.ac.jp
Fri Feb 15 07:44:42 EST 2008


Jon Wright wrote:
>
> Hi,
>
> To be honest I'd be nervous about spreading your depedencies all over 
> the disk, the potential interactions go as n^2. 

Well, I am more than nervous, this is totally insane, and I tried 
different things (registry: per application path, etc...). But it just 
looks like windows is even more f***-up than I thought. I am tired of 
wasting my time for this broken platform: I am really near giving up 
supporting MS compilers at all.

> According to msdn there 
> is a function which might work:
>
> "SetDllDirectory: Adds a directory to the search path used to locate 
> DLLs for the application."
> http://msdn2.microsoft.com/en-us/library/ms686203.aspx

Well, this does not sound right to me either; anyway, this is a C 
function which does not seem to be available from python.

> Otherwise you might have to copy the 
> mkl dll into the "directory from which the application loaded". This 
> would seem like a better choice, but I do wonder where that is for python.

This directory depends on how you start python, I think, so this is not 
better. Having looked at how installers do it, there does not seem to be 
much choice: either use PATH (actually, that's what the MKL is doing), 
or put everything in hardcoded directories (system32 and co). The other 
solution I see is to add the paths to the registry for the python 
application (it seems that windows has a registry subtree App Paths to 
handle per application dll path, but touching the registry makes me 
quite nervous too).
>
> Hope this helps. I'm certainly not an expert, but keen to try to support 
> your work on help the masses access optimised libraries.

Thanks,

David



More information about the NumPy-Discussion mailing list