I am getting segmentation faults when i require the ois module in any ruby script. I have no idea about rice, so I can't do much more than paste the error and cross my fingers :|
Program received signal SIGSEGV, Segmentation fault.
std::_Rb_tree<unsigned long, std::pair<unsigned long const, Rice::detail::Abstract_Caster*>, std::_Select1st<std::pair<unsigned long const, Rice::detail::Abstract_Caster*> >, std::less<unsigned long>, std::allocator<std::pair<unsigned long const, Rice::detail::Abstract_Caster*> > >::insert_unique (this=0x7ffff58e0df0, __v=...) at /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/include/g++-v4/bits/stl_tree.h:921
921 __comp = _M_impl._M_key_compare(_KeyOfValue()(__v), _S_key(__x));
Current language: auto
The current source language is "auto; currently c++".
(gdb) backtrace
\#0 std::_Rb_tree<unsigned long, std::pair<unsigned long const, Rice::detail::Abstract_Caster*>, std::_Select1st<std::pair<unsigned long const, Rice::detail::Abstract_Caster*> >, std::less<unsigned long>, std::allocator<std::pair<unsigned long const, Rice::detail::Abstract_Caster*> > >::insert_unique (this=0x7ffff58e0df0, __v=...) at /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/include/g++-v4/bits/stl_tree.h:921
\#1 0x00007ffff55ee978 in std::map<unsigned long, Rice::detail::Abstract_Caster*, std::less<unsigned long>, std::allocator<std::pair<unsigned long const, Rice::detail::Abstract_Caster*> > >::insert (klass=...) at /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/include/g++-v4/bits/stl_map.h:396
\#2 Rice::Data_Type<OIS::Pov>::bind<void> (klass=...) at /usr/local/include/rice/Data_Type.ipp:62
\#3 0x00007ffff55ead33 in define_class_under<OIS::Pov> (rb_mOIS=<value optimized out>) at /usr/local/include/rice/Data_Type.ipp:209
\#4 register_OIS_Pov (rb_mOIS=<value optimized out>) at _OIS_Pov.rb.cpp:19
\#5 0x00007ffff5643ae4 in register_OIS () at _OIS.rb.cpp:235
\#6 0x00007ffff5690e90 in Init_ois () at ois.rb.cpp:10
I'm using gentoo Linux, with the latest version of rbgccxml, rb++, rice and ogrerb
Well as a precursor: non of the ogrerb modules are in any known good workable state and/or meant to be used in any serious manner.
That said, it's been a while since I rebuilt the OIS wrapper and I've made some changes to Rice recently, so I'm not surprised that something might be broke. Thanks for the report.