Monday, February 22, 2010

Can't find tokyocabinet native extention

luan@luan-laptop:~/app/software/ruby/tokyo_projects$ ruby hash_db.rb
hash_db.rb:1:in `require': libtokyocabinet.so.9: cannot open shared object file: No such file or directory - /opt/ruby-1.9.1-p376/lib/ruby/site_ruby/1.9.1/x86_64-linux/tokyocabinet.so (LoadError)
from hash_db.rb:1:in `
'

he solution was to modify the LD_LIBRARY_PATH to include /usr/local/lib or to where the ruby lib is located.


Modified:

sudo vi .bashrc

#~/.bashrc

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib

No comments:

Post a Comment