MySQL Forums
Forum List  »  Connector/C++

Problems loading a lib, using mysql
Posted by: J Andersen
Date: April 24, 2009 07:30AM

On linux: I am creating a STAF service, which is basically a shared library that is loaded manually (with dlopen or similar). The library compiles and links with no errors, but won't load:

# STAFProc
Caught STAFException
Name : STAFException
Location : /opt/dev/autobuild/build/src/staf/stafif/STAFDynamicLibraryInlImpl.cpp(29)
Text : STAFDynamicLibraryOpen: /usr/local/staf/lib/ undefined symbol: _ZN3sql5mysql25get_mysql_driver_instanceEv
Error code: 10
Error reading config file

However, ldd says:

# ldd /usr/local/staf/lib/ => /lib/ (0x00002b2fcad12000) => /lib/ (0x00002b2fcae28000) => /lib/ (0x00002b2fcaf5c000) => not found => /usr/lib/ (0x00002b2fcb060000) => /usr/lib/ (0x00002b2fcb362000) => /lib/ (0x00002b2fcb560000) => /lib/ (0x00002b2fcb6e3000) => /lib/ (0x00002b2fcb7f0000)
/lib64/ (0x0000555555554000) => /lib/ (0x00002b2fcba2d000) => /usr/lib/ (0x00002b2fcbb45000)

So it clearly finds What is wrong here? Is it the wrong library I link against?

Options: ReplyQuote

Written By
Problems loading a lib, using mysql
April 24, 2009 07:30AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.