Looks like ruby bindings dependencies are not searched properly. For example, on fresh Gentoo install (with ruby and swig installed) there's no such file as /usr/lib/libruby.so (on my other Gentoo machines such symlink is dated 2005 so this must have been dropped years ago)
For now the workaround is:
ln -s libruby.so.1.8 libruby.so
Is there some sort of ruby development package for gentoo? The unversioned symlinks for ruby tend to be in -devel packages on other linux distributions.