Community Packages

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#23772 - [unixodbc][myodbc] Driver Manager can't open lib

Attached to Project: Community Packages
Opened by Marc Rechté (mrechte) - Friday, 15 April 2011, 06:50 GMT
Last edited by Sergej Pupykin (sergej) - Tuesday, 12 July 2011, 14:23 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sergej Pupykin (sergej)
Architecture i686
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 2
Private No


Trying to connect produces the following error:

[mrechte@linux2 ~]$ isql geslogweb -v
[01000][unixODBC][Driver Manager]Can't open lib '/usr/lib/' : file not found
[ISQL]ERROR: Could not SQLConnect

Additional info:
* package version(s)
[mrechte@linux2 ~]$ pacman -Q unixodbc myodbc
unixodbc 2.3.0-1
myodbc 5.1.8-1

* config and/or log files etc.
[mrechte@linux2 ~]$ ldd /usr/lib/ => (0xb76e7000) => /usr/lib/ (0xb6d6a000) => /usr/lib/ (0xb6ab8000) => /lib/ (0xb6a9f000) => /lib/ (0xb6a79000) => /lib/ (0xb6a6f000) => /usr/lib/ (0xb6a1e000) => /usr/lib/ (0xb68a4000) => /lib/ (0xb68a0000) => /usr/lib/ (0xb688b000) => /usr/lib/ (0xb687d000) => /lib/ (0xb6730000) => /usr/lib/ (0xb6714000)
/lib/ (0xb76e8000)

[mrechte@linux2 ~]$ file /usr/lib/
/usr/lib/ ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), dynamically linked, not stripped

[mrechte@linux2 ~]$ file /usr/bin/isql
/usr/bin/isql: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, stripped

[mrechte@linux2 ~]$ dltest /usr/lib/
[dltest] ERROR dlopen: file not found

Description = ODBC Driver for MySQL
Driver = /usr/lib/
Setup = /usr/lib/
FileUsage = 1

[mrechte@linux2 ~]$ cat /etc/odbc.ini
Description = MySQL geslog Web
Driver = MySQL
Server = localhost
Database = geslogweb
Port = 3306
Socket = /tmp/mysql.sock
Option =
Stmt =

Steps to reproduce:
This task depends upon

Closed by  Sergej Pupykin (sergej)
Tuesday, 12 July 2011, 14:23 GMT
Reason for closing:  Fixed
Comment by Elisamuel Resto (user00265) - Monday, 30 May 2011, 06:26 GMT
I am having the same issue with the same versions as reported, and I tried a sad attempt at fixing, but no luck.

I tried the PostgreSQL ODBC driver and dltest worked fine with it, I tried rebuilding the myodbc package and it still had the same issues and I tried changing the paths to the library but it had no effect.

It seems as though the issue might be with unixODBC and MyODBC -- perhaps a compatibility issue?
Comment by Reynaldo (skraelings) - Wednesday, 15 June 2011, 05:11 GMT
Not sure the reason libtool fails to load, but after reading this">, I removed myodbc and downloaded directly from which happen to have libtool library files *.la

Using unixodbx's dltest results in successul loading.
Comment by Marc Rechté (mrechte) - Wednesday, 15 June 2011, 07:29 GMT
Thanks a lot Reynaldo, it is now working for I.

I did not uninstall myodbc (just to keep a track), and overwrote with the downloaded files (check pacman -Ql myodbc).

Comment by Elisamuel Resto (user00265) - Saturday, 18 June 2011, 00:16 GMT
OK, so I looked at the PKGBUILD in the community repository and I see a few things:
* The following ./configure switches are no longer valid: --disable-qt, --without-samples and --enable-thread-safe
* The CFLAGS and LDFLAGS are being reset, this is the reason why the build is not working with dltest
* The '-lmysqld' flag in LDFLAGS does absolutely nothing. There is no such .so anywhere (though there is a .la)

Overall this PKGBUILD looks like its just being 'kept up to date' but the format doesn't look like any other PKGBUILDs I've seen in the repos. I propose the attached patch to PKGBUILD that compiles a MySQL ODBC connector that loads properly with dltest.
Comment by Sergej Pupykin (sergej) - Tuesday, 12 July 2011, 14:22 GMT
Elisamuel, thanks for patch. myodbc updated, isql works.