[Numpy-discussion] Extension under windows

Paul F Dubois paul at pfdubois.com
Wed Apr 17 07:17:07 EDT 2002

You need to link with the Python library. I suggest you learn to use
distutils and then it will load for you correctly on both platforms. The
file "setup.py" in the Numeric source distribution is a good if
complicated example. Some of the setup.py files in the Packages area are
simpler and easier to understand.

-----Original Message-----
From: numpy-discussion-admin at lists.sourceforge.net
[mailto:numpy-discussion-admin at lists.sourceforge.net] On Behalf Of
Sent: Tuesday, April 16, 2002 11:09 AM
To: numpy-discussion at lists.sourceforge.net
Subject: [Numpy-discussion] Extension under windows

Dear Numerical Python Users,

I have writen an extension using  GSL (Gnu Scientific Library) and
Numerical Python. This extension work fine under Linux and I would to do
the same under Windows. For that I use Cygwin. When I would create the

$ gcc -shared Example.o -o Example.pyd

I receive this message :

Example.o<.text+0x58>:Example.c: undefined reference to
Example.o<.text+0x15e>:Example.c: undefined reference to 'Py_BuildValue'

Example.o<.text+0x1b1>:Example.c: undefined reference to
Example.o<.text+0x1c1>:Example.c: undefined reference to
Example.o<.text+0x1db>:Example.c: undefined reference to
Example.o<.text+0x1f4>:Example.c: undefined reference to
Example.o<.text+0x206>:Example.c: undefined reference to
Example.o<.text+0x214>:Example.c: undefined reference to

Perhaps this command is wrong.

Perhaps, anyone could explain or show me a document which explain the
procedure clearly ?

Thanks in advance for your help


Numpy-discussion mailing list Numpy-discussion at lists.sourceforge.net

More information about the NumPy-Discussion mailing list