Subject:
Re: [ruby-ffi] Proper way to refer to libcrack.so.2
From:
Matijs van Zuijlen
Date:
5/11/12 3:55 AM
To:
ruby-ffi@googlegroups.com

Something like that would be great. A helper method to list available versions would also be nice; I'm now relying on a rather unpleasant set of rescue blocks to load either the preferred version or an unsupported version of a library (with proper warnings shown, of course).

On 05/11/2012 08:59 AM, postmodern wrote:
This brings up a feature I wanted to request. Most Linux distributions
have moved the primary "libfoo.so" file into "foo-dev" or "foo-devel"
packages, with the "libfoo" package containing "libfoo.so.X". Maybe in
the future, you could specify the Major version of the library you wish
to load?

     ffi_lib 'crack', '>= 2' # loads "libcrack.so.2"

On 05/10/2012 11:40 PM, broberts wrote:
On CentOS cracklib is deploy as libcrack.so.2 which is a symlink to
libcrack.so.2.8.1. There is no libcrack.so. Referring to this library
using:

ffi_lib 'crack'

fails with a file not found error. Referring to the library using:

ffi_lib 'crack.so.2'

succeeds. I assume that this is the expected behavior but I wanted to
make sure before I get too far down the road.

Thanks for any help.

Baron

-- 
Matijs