Subject:
Re: [ruby-ffi] Re: Having trouble with a struct
From:
Wayne Meissner
Date:
11/4/10 1:54 AM
To:
ruby-ffi@googlegroups.com

On 4 November 2010 10:24, Qwerty <qwerty123451910@hotmail.com> wrote:
> 1. Open suse 11.3 kernel: 2.6.34.7-0.5-desktop #1 SMP PREEMPT.
> Intel(R) Core(TM)2 Duo CPU E8400 @ 3.00GHz

Is your ruby running as 32bit or 64bit?

>
> 2. I tried it with JRuby 1.5.2 and got an error about pack being
> undefined. I tried the alias packed with no luck. The JRuby ffi gem
> directory only has 1 file ffi-0.6.3-java/lib/ffi.rb. Are the other
> files outside this directory? The docs only show the 3 methods defined
> in that file(Pointer), yet is doesn't complain about FFI::Struct.

All of FFI for JRuby is contained in JRuby itself - the ffi gem is
just a shim to satisfy gem dependencies (and occasionally used to
patch the API post release).

At least this bug is easily reproducable, so shouldn't be too hard to
track down where in StructLayoutBuilder the problem is.