Problems compiling gtk-2.4 on Solaris 9

I've had nothing but problems attempting to compile gtk-2.4 on Solaris
9 (then again, I have nothing but problems trying to compile anything
on Solaris).

Currently, here are the packages I'm trying to install and the
relevant configure options...
glib-2.4.8       configure --enable-threads --with-libiconv=gnu
atk-1.8.0        configure --prefix=/usr/local/gtk-2.4
pango-1.6.0    configure --prefix=/usr/local/gtk-2.4
gtk+-2.4.14     configure --prefix=/usr/local/gtk-2.4

for glib, atk, and pango, the configure flags were sufficient, and I
set my PKG_CONFIG_PATH env var to :

I'm using the libiconv, expat, and zlib packages from 
It was necessary to set the CFLAGS env var to
-I/usr/local/gtk-2.4/include/pango-1.0 -I/usr/sfw/include
-I/usr/sfw/include/freetype2" in order to get the freetype2
dependencies of gtk to resolve. This is Sun's freetype2, I'm not sure
which version. I tried compiling freetype 2.1.9 and linking against
that, but the Xsun header files didn't seem to work with it.

Everything seems to configure and compile without errors in this
configuration, but when I try to run any of various gtk utilities
(let's use gtk-demo for example), I get the following error:

[grega maul:/usr/local/gtk-2.4/bin] $ ./gtk-demo ./gtk-demo: fatal: relocation error: file
/usr/local/gtk-2.4/lib/ symbol gdk_threads_lock:
referenced symbol not found
[grega maul:/usr/local/gtk-2.4/bin] $ 

Here's the output of ldd on gtk-demo, just to show that it is using
the version of gtk that I compiled, not the ones that are shipped as
part of Sun Gnome 2.0 Desktop which can be found in /usr/lib:

[grega maul:/usr/local/gtk-2.4/bin] $ ldd gtk-demo =>       
/usr/local/gtk-2.4/lib/ =>   /usr/local/gtk-2.4/lib/ =>   /usr/local/gtk-2.4/lib/ =>  /usr/lib/ =>   /usr/lib/ =>    /usr/lib/ =>   /usr/lib/ =>        /usr/lib/ =>   /usr/lib/ =>  /usr/local/gtk-2.4/lib/ =>    /usr/local/gtk-2.4/lib/ =>     /usr/local/gtk-2.4/lib/ =>       /usr/local/gtk-2.4/lib/ =>   /usr/local/gtk-2.4/lib/ =>   /usr/local/gtk-2.4/lib/ =>    /usr/lib/ =>      /usr/local/gtk-2.4/lib/ =>         /usr/local/lib/ =>     /usr/lib/ =>     /usr/lib/ =>         /usr/local/lib/ =>       /usr/sfw/lib/ =>         /usr/local/lib/ =>      /usr/sfw/lib/ =>   /usr/openwin/lib/ =>     /usr/local/lib/ =>    /usr/lib/ =>  /usr/local/gtk-2.4/lib/ (SUNW_1.1) =>  (version not found) =>         /usr/lib/ =>    /usr/lib/ =>  /usr/lib/ST/ =>       /usr/lib/ =>       /usr/lib/ =>  /usr/lib/ =>  /usr/lib/ =>   /usr/lib/
        /usr/platform/SUNW,Sun-Blade-100/lib/ =>        /usr/lib/
[grega maul:/usr/local/gtk-2.4/bin] $

And when I use nm to try to inspect the library that's being
complained about (/usr/local/gtk-2.4/lib/, and
look for the undefined symbol, gdk_threads_lock, I get the following:

[grega maul:/usr/local/gtk-2.4/bin] $ nm
/usr/local/gtk-2.4/lib/ | grep gdk_threads_lock
[20594] |         0|       0|NOTY |GLOB |0    |UNDEF  |gdk_threads_lock
[grega maul:/usr/local/gtk-2.4/bin] $

So it looks like my problem is that somehow in the compilation
process, gdk_threads_lock ends up UNDEF in the library. I originally
thought it was because I didn't use --enable-threads for the configure
of glib, but I added that and the symbol is still undefined.

Anyone have any ideas?

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]