[egenix-users] Non-standard location for iODBC, libiodbc.so.2 not
found
Joseph Kocherhans
joseph.kocherhans at hsc.utah.edu
Wed Aug 18 16:22:57 CEST 2004
I've been having trouble with the packaged versions of iodbc and
freetds on debian, so I decided to try building them both from source.
I put iodbc in /opt/iodbc, and tested the freetds odbc driver with
iodbctest. Everything looks good. I modified mxCOMMERCIAL.py to:
Extension('mx.ODBC.iODBC.mxODBC',
['mx/ODBC/iODBC/mxODBC.c',
'mx/ODBC/iODBC/mxSQLCodes.c'
],
include_dirs=['mx/ODBC/iODBC',
'/opt/iodbc/include'],
define_macros=[('iODBC', None),
('MAX_COLUMN_NAME_LENGTH', '50')],
library_dirs=['/opt/iodbc/lib'],
libraries=['iodbc']
),
Everything builds fine, (running "python2.3 setup.py install") but when
I try to import mx.ODBC.iODBC in python2.3, I get the following error:
Traceback (most recent call last):
File "/home/jkocherhans/mxodbctest.py", line 1, in ?
from mx.ODBC.iODBC import DriverConnect
File "/usr/lib/python2.3/site-packages/mx/ODBC/iODBC/__init__.py",
line 8, in ?
from mxODBC import *
ImportError: libiodbc.so.2: cannot open shared object file: No such
file or directory
Is there something besides include_dirs and library_dirs I need to
change to use the iODBC I installed in /opt?
Thanks,
Joseph Kocherhans
More information about the egenix-users
mailing list