[fxruby-users] undefined symbol
Joel VanderWerf
vjoel at PATH.Berkeley.EDU
Mon Dec 6 13:27:07 EST 2004
Jeroen van der Zijp wrote:
> On Sunday 05 December 2004 05:36 pm, Joel VanderWerf wrote:
>
>>Ok, the latest snapshots of ruby have fixed the st.h prototypes so that
>>FXRuby-1.2.2 builds. But now I've got a new (actaully, old) problem.
>>
>>$ ruby styledtext.rb
>>/usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so:
>>/usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so: undefined symbol:
>>_ZN8FXWindow10stringTypeE -
>>/usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so (LoadError)
>> from styledtext.rb:3
>>
>>These are fresh builds of FXRuby-1.2.2 and fox-1.2.11 on linux using gcc
>>3.2.2, ruby 1.8.2 (2004-11-18) [i686-linux].
>>
>>
>>I've had this problem before with new versions of Fox/FXRuby, but was
>>never able to fix it. Here's some more information:
>>
>>$ ldd /usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so
>> libFOX-1.2.so.0 => /usr/local/lib/libFOX-1.2.so.0 (0x4066d000)
>> ....
>>
>>$ nm /usr/local/lib/libFOX-1.2.so.0 | grep stringType
>>0029eb94 R _ZN2FX8FXWindow10stringTypeE
>>
>>
>>So it appears that maybe symbol mangling is working differently between
>>fox and fxruby?
>>
>> _ZN8FXWindow10stringTypeE is what FXRuby is looking for.
>>
>> _ZN2FX8FXWindow10stringTypeE is what Fox has generated.
>>
>>I know little about C++ symbols but it looks like the latter symbol is
>>in the FX namespace, but the former is not.
>>
>>Any suggestions?
>
>
> I think Lyle may know more about FXRuby, but to me it looks like a namespace
> issue. FOX 1.0 didn't support namespaces, but in FOX 1.2, all symbols are
> in the FX namespace.
>
> Is it possible you have both the 1.0 and the 1.2 headers installed?
I do have both sets of headers installed. (But why should this be a
problem? FXRuby-1.2 should look in fox-1.2, right?)
Anyway, the 1.0 headers were in /usr/local/include/fox. The 1.2 headers
are in /usr/local/include/fox-1.2. They don't appear to be anywhere else.
I tried renaming /usr/local/include/fox to /usr/local/include/fox-1.0.
Then I started from scratch with FXRuby-1.2.2, and rebuilt and installed
as usual. Same problem:
$ ruby table.rb
/usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so:
/usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so: undefined symbol:
_ZN8FXWindow10stringTypeE -
/usr/local/lib/ruby/site_ruby/1.8/i686-linux/fox12.so (LoadError)
from table.rb:3
Maybe I should just clean every fox-related file from my system and
truly start from scratch.
More information about the fxruby-users
mailing list