ts <decoux / moulon.inra.fr> wrote in message news:<200409291003.i8TA3od00568 / moulon.inra.fr>...
> >>>>> "D" == Daniel Berger <djberg96 / hotmail.com> writes:
> 
> D> static VALUE ks_allocate(VALUE klass){
> D>    KstatStruct* ptr = malloc(sizeof(KstatStruct));
> D>    return Data_Wrap_Struct(klass,0,ks_free,ptr);
> D> }
> 
>  I don't understand this when you have a nice Data_Make_Struct()
> 
> D> VALUE ks_record(VALUE self){
> D>    VALUE rbMHash, rbIHash, rbNHash, rbSHash;
> 
>       VALUE rbMHash, rbIHash, rbNHash;
>       volatile VALUE rbSHash;
> 
> 
> Guy Decoux

Argh!  I forgot to mention that I built Ruby with the
--disable-largefile option.  Once I rebuilt Ruby without that option,
it worked, although with warnings:

In file included from /opt/lib/ruby/1.8/sparc-solaris2.9/ruby.h:21,
                 from rkstat.c:4:
/opt/lib/ruby/1.8/sparc-solaris2.9/config.h:16:1: warning:
"_FILE_OFFSET_BITS" redefined
In file included from
/opt/csw/gcc3/lib/gcc-lib/sparc-sun-solaris2.8/3.3.3/include/sys/types.h:28,
                 from /usr/include/kstat.h:10,
                 from rkstat.c:1:
/usr/include/sys/feature_tests.h:96:1: warning: this is the location
of the previous definition

However, this puts me in a dilemma, since removing that option means I
can't build any extensions that use procfs.h, unless I want to build
with the -m64 option (which I don't).  See ruby-talk 67160 and 77026
for more on that issue.

Any suggestions from here?  How were you able to build without that
warning?  And do you know how to resolve the procfs.h issue?

Regards,

Dan