MagLev/maglev — Issue #108: FFI doesn't follow symbolic links to libraries
Author: timfel
Created: 2011-11-17 10:40:58+00:00
State: open

It says it does in `CLibrary>>load`, but on my machine it doesn't seem to work.

# ls -l /lib/x86_64-linux-gnu/libc.so.6
lrwxrwxrwx 1 root root 12 2011-10-12 00:28 /lib/x86_64-linux-gnu/libc.so.6 -> libc-2.13.so
# maglev-irb
>> module Ext; extend FFI::Library; end
=> Ext
>> Ext.ffi_lib("libc.so.6")
=> [["libc.so.6"], [#]]
>> Ext.attach_function :malloc, [:size_t], :pointer
FFI::NotFoundError: Unable to find FFI 'malloc' in library: *snip*
>> Ext.ffi_lib("libc-2.13.so")
=> [["libc-2.13.so"], [#]]
>> Ext.attach_function :malloc, [:size_t], :pointer
=> #