[Mapserver-users] Python Mapscript setup and import

Sean Gillies sgillies at frii.com
Thu Jun 24 14:05:32 EDT 2004


On Jun 24, 2004, at 11:35 AM, Ken Bolton wrote:

> Hi MapServer-Users List,
>
> I am trying to use a system that relies on python mapscript. I have 
> successfully configured and compiled MapServer 4.2. From there, i go 
> to the mapscript/python/ directory and have run both "sudo python 
> setup.py install" and "sudo python setup_wnone.py install". In either 
> instances, when I invoke the python interpreter and attempt to import 
> mapscript, I get an error. I've googled and searched the list, but 
> can't find anything. Is there something obvious I'm missing? The 
> interpreter session is below. Is there any other info that would be 
> helpful in solving this?
>
> cheers,
> Ken
>
> Python 2.3.4 (#2, Jun 19 2004, 18:15:30)
> [GCC 3.3.4 (Debian)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import mapscript
> Traceback (most recent call last):
>   File "<stdin>", line 1, in ?
>   File "/usr/lib/python2.3/site-packages/mapscript.py", line 4, in ?
>     import _mapscript
> ImportError: /usr/lib/python2.3/site-packages/_mapscript.so: undefined 
> symbol: msSaveImage

Don't use setup_wnone.py.

Did you run SWIG yourself to generate the mapscript_wrap.c file
or are you using the wrapper from the distribution?

Also, if you are a IRC user, me and another Python mapscript user
are currently on irc.freenode.net #mapserver

Sean

--
Sean Gillies
sgillies at frii dot com
http://users.frii.com/sgillies




More information about the mapserver-users mailing list