silpol / pyspatialite

Automatically exported from code.google.com/p/pyspatialite
zlib License
0 stars 0 forks source link

_iconv not linked to binary #2

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Download pyspatialite 2.6.1
2. do "sudo python setup.py install"
3. In python interpreter run "from pyspatialite import dbapi2"

What is the expected output? What do you see instead?

Expected output is a new line.

I see the following error:

Python 2.7.1 (r271:86882M, Nov 30 2010, 10:35:34) 
[GCC 4.2.1 (Apple Inc. build 5664)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from pyspatialite import dbapi2 
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pyspatialite/dbapi2.py", line 27, in <module>
    from pyspatialite._spatialite import *
ImportError: 
dlopen(/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-pack
ages/pyspatialite/_spatialite.so, 2): Symbol not found: _iconv
  Referenced from: /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pyspatialite/_spatialite.so
  Expected in: flat namespace
 in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pyspatialite/_spatialite.so

What version of the product are you using? On what operating system?

I am using 2.6.1 on Mac OS X 10.6.7

Please provide any additional information below.

I solved this for myself by adding 'iconv' to the libraries list in setup.py

Original issue reported on code.google.com by afarn...@gmail.com on 29 Mar 2011 at 3:43

GoogleCodeExporter commented 8 years ago
Hmm - the current version has iconv in the list.  I really need to switch and 
use autoconf or the like to generate the compile flags, because there are some 
many possibilites - the geo libs have 4 different combinations, and in many 
kernels iconv is now included in libc.  I'm not going to fix this, for now, 
though I may need to release a new package based on current source.

Original comment by lok...@gmail.com on 29 Mar 2011 at 3:50

GoogleCodeExporter commented 8 years ago
Cool, I really just wanted to get it documented since I figured out a fix 
anyhow. Thanks for the great library!

Original comment by afarn...@gmail.com on 29 Mar 2011 at 3:51