Re: Linker Errors with Fox 1.6 on Ubuntu 22.04

[email protected] Mon, 13 May 2024 09:10:42 -0500
Newsgroups gmane.comp.lib.fox-toolkit.user
Message-ID <[email protected]>
On 2024-05-09 18:07, Dustin Inkster wrote:
> Hi,
> 
> I'm attempting to run the scribble tutorial but I'm having some
> trouble with linker errors.  I'm using:
> 
> g++ `pkgconfig --cflags --libs fox` scribble.cpp
> 
> to compile, which yields a ton of linker errors (for each token in the
> program, looks like).  Here's an example:
> 
> /usr/bin/ld:
> /tmp/cc7MpCOs.o:(.data.rel.ro._ZTV14ScribbleWindow[_ZTV14ScribbleWindow]+0x20):
> undefined reference to `FX::FXObject::onDefault(FX::FXObject*,
> unsigned int, void*)'
> 
> My pc file is
> 
> /usr/local/lib/pkgconfig/fox.pc
> 
> When I enter _pkg-config --modversion fox _I get _1.6.56 _so it
> appears to find the pc file. It is set to look for the include files
> in
> 
> /usr/local/include/fox-1.6
> 
> My fx.h is there like it should be and includes FXObject.h (and all
> the others). For my libraries it looks in
> 
> /usr/local/lib
> 
> Where I can find libFOX-1.6.a.  Running _ar t libFOX-1.6.a _gives me a
> long list of object files (including FXObject.o).  Everything appears
> to be in order, yet I still get the errors.  I'd appreciate any help
> on what to look at next.  Thanks.
> 
> Dustin

First off, consider upgrading to a newer version of FOX, 1.6 is getting 
too old.

I just rebuilt 1.6.57 and I am encountering no problems.  Perhaps this 
is
a library search path issue.  Perhaps LD_LIBRARY_PATH setting will fix
your issue??

    -- JVZ