[Pyrex] Undefined references message when compiling

Greg Ewing greg.ewing at canterbury.ac.nz
Fri May 18 01:18:46 UTC 2007


stephen at theboulets.net wrote:

> D:\Data\csb046\programming\python\pyrex>gcc pyrex_ex1.c -o pyrex_ex1.o

There's no -c in that command, so it's trying to link
it into a complete program instead of just compiling.

But unless you intend to link it statically with the
Python interpreter, you don't want a .o anyway, you
want a .pyd (which is a kind of dll). I don't know
what the magic command for that is using mingw on
Windows. It's probably easier to let distutils do
it for you -- look for info on how to make distutils
work with mingw.

--
Greg



More information about the Pyrex mailing list