What is a .pyd file
Dave Brueck
dbrueck at edgix.com
Wed Apr 11 11:31:51 EDT 2001
> I understand .py, .pyw, .pyc and .dll files. However, I see .pyd files in
> the ActiveState Python 2.0.203 tree, e.g., multiarray.pyd in the Numeric
> directory; also much of the win32 extensions. multiarray.pyd looks like a
> Windows DLL and dumpbin seems to agree. Is it built as a DLL and then
> renamed? If so, why?
Hi David,
You and dumpbin are right, it is a Windows DLL. The extension is just a
convenient way of marking the file as a Python extension module. This is
particularly useful if your extension module wraps an already-existing
third-party C library. For example, if you saw in your directory:
opengl.dll
opengl.pyd
then it'd be a reasonable bet that the first is the C library and the second
is a Python extension module that uses it.
-Dave
More information about the Python-list
mailing list