Unable to access fireruby lib

I am getting the following controller exception when trying to access my newly installed Firebird DB (to replace MySQL) from my app.

libfbclient.so.1: cannot open shared object file: No such file or directory - /usr/local/lib/ruby/gems/1.8/gems/fireruby-0.4.0-i586- linux/lib/fr_lib.so

I have installed the fireruby gem using "sudo gem install fireruby" and the file can be found on my filesystem by following the path above.

Any ideas most appreciated. The fireruby wiki is unavailable.

Thanks, Lee.

The problem is that fireruby can not find libfbclient.so.1. You need to find the path to this file on your system and add that path to either the LD_LIBRARY_PATH or you can add it to /etc/ld.so.conf then run /sbin/ldconfig. This should solve the issue. Here is a page explaining shared libraries a bit more in depth:

http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html

Lee wrote:

The problem is that fireruby can not find libfbclient.so.1. You need to find the path to this file on your system and add that path to either the LD_LIBRARY_PATH or you can add it to /etc/ld.so.conf then run /sbin/ldconfig. This should solve the issue. Here is a page explaining shared libraries a bit more in depth:

http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html

Lee wrote:

Thanks. Very helpful.

I looked for the file and could only find a link (libfbclient.so.2) to the file libfbclient.so.2.0.1 in Firebird's /lib directory.

So I created a link called libfbclient.so.1 to point to the same file.

This solved the problem - I can now reach the database from my rails app.

I assume fireruby is expecting a libfbclient file for Firebird 1.x.x whereas I have installed Firebird 2.0.1.