[unixODBC-support] How to make a 32 bit application work with unixodbc in a 64 bit environment

arkangelboss at gmail.com arkangelboss at gmail.com
Wed Apr 6 14:09:37 BST 2011


Hi all,

I'm working with ubuntu 10.10 and unixodbc 2.2.14p2-1ubuntu1 in a AMD64
environment.
I need to make work a 32 bit application through the odbc interface, but it
refuses to SQLConnect. To better debug I've downloaded the i386 versions of
both the unixodbc and the driver I need (postgresql-odbc), I've set up the
odbcinst.ini to point the i386 driver. When using the i386 isql, downloaded
with the i386 unixodbc, it complains

[01000][unixODBC][Driver Manager]Can't open lib
'/usr/lib32/odbc/psqlodbca.so' : file not found

while the file, which is the i386 postgresql driver I downloaded, is
actually there.

It seems to me that the problem is in the mixed i386/AMD64 chain...

Is it possible to set up a unixodbc installation so that a i386 executable
will pass through a i386 driver manager and load the appropriate driver as
stated in odbcinst.ini?

This is what it looks like:

[PostgreSQL ANSI]
Description        = PostgreSQL ODBC driver (ANSI version)
Driver        = /usr/lib/odbc/psqlodbca.so
Setup        = /usr/lib/odbc/libodbcpsqlS.so
Debug        = 0
CommLog        = 1
FileUsage       = 1
UsageCount    = 1

[PostgreSQL Unicode]
Description        = PostgreSQL ODBC driver (Unicode version)
Driver        = /usr/lib/odbc/psqlodbcw.so
Setup        = /usr/lib/odbc/libodbcpsqlS.so
Debug        = 0
CommLog        = 1
FileUsage       = 1
UsageCount    = 1

[PostgreSQL 32]
Description        = PostgreSQL ODBC driver 32bit (ANSI version)
Driver        = /usr/lib32/odbc/psqlodbca.so
Setup        = /usr/lib32/odbc/libodbcpsqlS.so
Debug        = 0
CommLog        = 1
FileUsage       = 1
UsageCount    = 1

[MySQL]
Description     = MySQL driver
Driver          = /usr/lib/odbc/libmyodbc.so
Setup           = /usr/lib/odbc/libodbcmyS.so
CPTimeout       =
CPReuse         =
FileUsage       = 1


Thanks for your help!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.unixodbc.org/pipermail/unixodbc-support/attachments/20110406/1eb95044/attachment.html>


More information about the unixODBC-support mailing list