swig and init_module or initmodule, windows XP

Thomas Heller theller at python.net
Tue Jun 17 10:51:46 EDT 2003


"Jung-Paz" <jung-paz at t-online.de> writes:

> Hi !
>
> I am new to Python and Swig ...
>
> I am using Python2.2, mingw and Swig 1.3.19, Windows XP, and trying to build
> a module using the distutils.
> Basically it works, but in the final linking step I get an undefined
> reference to "initexample" (the module name is example).
> This sounds reasonable, as the file example_wrap.c, as produced by swig,
> contains only a function "init_example.c".
> If I replace "init_example" by hand with "initexample" and compile and link
> by hand, everything is fine, and I get a loadable and usable module.
> Any idea how I could make swig to produce other function names, or whatever
> could help ?

Sounds like you should name your extension _example.pyd instead of
example.pyd...

Thomas




More information about the Python-list mailing list