467,225 Members | 1,368 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,225 developers. It's quick & easy.

SWIG/Python2.4.1: "ImportError: dynamic module does not define init function (initSHIP)"

Hello,

I am using SWIG-1.3.24 to make an extension (called SHIP) to Python2.4.1 and
then running under IDLE (if that makes any difference) but when I "import
SHIP" I get:
import SHIP
Traceback (most recent call last):
File "<pyshell#0>", line 1, in -toplevel-
import SHIP
ImportError: dynamic module does not define init function (initSHIP)


Indeed, SHIP.py does not define an initSHIP. It does have "import _SHIP"

SHIP_wrap.cpp (produced by SWIG) does have init_SHIP (defined to SWIG_init).

It seems to me I should not be editing SHIP.py (as made by SWIG) but it does
seem to be missing something, or am I?

Thanks in advance,

Bill

PS I gave up trying to use IDLE with a locally compiled debug version of
Python - that's for another day (or week), but thanks for the assorted help
I was given.
Jul 19 '05 #1
  • viewed: 2438
Share:

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Sebastian Stelzer | last post: by
5 posts views Thread by Studio P.M. | last post: by
reply views Thread by Terry Tang | last post: by
reply views Thread by Robert Dailey | last post: by
reply views Thread by Adict | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.