Re: problem linking 'pango-1.14.4'




--- Sergei Steshenko <sergstesh yahoo com> wrote:

> Hello All,
> 
> as I wrote recently, I'm checking my tool (see signature) on a different distro -
> originally it was developed on Mandriva, now I'm checking it on MEPIS, which is
> kind of Ubuntu.
> 
> 'configure' for 'pango-1.14.4' completed with 0 status, however, 'make' fails; the
> failing command is:
> 
> "
> gcc -g -O2 -Wall -o .libs/pango-view renderdemo.o viewer-x.o viewer-main.o pango-view.o
> viewer-pangox.o viewer-pangoft2.o viewer-cairo.o viewer-pangocairo.o -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/freetype-2.2.1/lib  -L/mnt/hdd2/sergei/install/zlib-1.2.3/lib
> ../pango/.libs/libpango-1.0.so -L/mnt/hdd2/sergei/install/glib-2.12.3/lib
> ../pango/.libs/libpangox-1.0.so -L/usr/X11R6/lib -L/mnt/hdd2/sergei/install/fontconfig-2.4.1/lib
> -L/mnt/hdd2/sergei/install/freetype-2.2.1/lib ../pango/.libs/libpangoft2-1.0.so
> ../pango/.libs/libpangocairo-1.0.so -L/mnt/hdd2/sergei/install/cairo-1.2.4/lib
> -L/mnt/hdd2/sergei/install/libpng-1.2.12/lib
> /mnt/hdd2/sergei/build/pango-1.14.4/pango/.libs/libpangoft2-1.0.so
> /mnt/hdd2/sergei/build/pango-1.14.4/pango/.libs/libpango-1.0.so
> /mnt/hdd2/sergei/install/glib-2.12.3/lib/libgobject-2.0.so
> /mnt/hdd2/sergei/install/glib-2.12.3/lib/libgmodule-2.0.so -ldl
> /mnt/hdd2/sergei/install/glib-2.12.3/lib/libglib-2.0.so -lrt
> /mnt/hdd2/sergei/install/cairo-1.2.4/lib/libcairo.so
> /mnt/hdd2/sergei/install/fontconfig-2.4.1/lib/libfontconfig.so
> /mnt/hdd2/sergei/install/freetype-2.2.1/lib/libfreetype.so /usr/lib/libexpat.so
> /mnt/hdd2/sergei/install/libpng-1.2.12/lib/libpng12.so -lz -lXrender -lm -lX11 -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/pango-1.14.4/lib -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/glib-2.12.3/lib -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/cairo-1.2.4/lib -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/fontconfig-2.4.1/lib -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/freetype-2.2.1/lib -Wl,--rpath
> -Wl,/mnt/hdd2/sergei/install/libpng-1.2.12/lib
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderFindDisplay': undefined reference to
> `XextFindDisplay'
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderFindDisplay': undefined reference to
> `XextAddDisplay'
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderCloseDisplay': undefined reference
> to
> `XextRemoveDisplay'
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderQueryVersion': undefined reference
> to
> `XMissingExtension'
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderQueryFormats': undefined reference
> to
> `XMissingExtension'
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderFindVisualFormat': undefined
> reference
> to `XMissingExtension'
> /usr/X11R6/lib/libXrender.a(Xrender.o): In function `XRenderFindFormat': undefined reference to
> `XMissingExtension'
> /usr/X11R6/lib/libXrender.a(Composite.o): In function `XRenderComposite': undefined reference to
> `XMissingExtension'
> /usr/X11R6/lib/libXrender.a(Glyph.o): more undefined references to `XMissingExtension' follow
> collect2: ld returned 1 exit status
> ".
> 
> Seeing this I can't quite figure out where the problem is.
> 
> Is it the wrong (something missing in it) 'gcc g -O2 -Wall ...' command line ?
> 
> Is it defective /usr/X11R6/lib/libXrender.a ?
> 
> Should the latter be scanned more than once during linking ?
> 
> Should 'configure' have caught this problem ?
> 
> On Mandriva this all works fine.
> 
> Thanks,
>   Sergei.
> 
> Applications From Scratch: http://appsfromscratch.berlios.de/
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 
> _______________________________________________
> gtk-list mailing list
> gtk-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-list
> 


OK, I did some digging into the matter and this is what I found - I started
with XRenderFindDisplay unresolved name.

On Mandriva, where my tool worked OK without any additional efforts,
Xrender library is in /usr/X11R6/lib/libXrender.so file, and this file/library
defines XRenderFindDisplay symbol:

"
[13] 23:32 sergei comp home net:/ibm/home/sergei> nm -A -C -D /usr/X11R6/lib/libXrender.so | grep
XRenderFindDisplay
/usr/X11R6/lib/libXrender.so:00001670 T XRenderFindDisplay
[14] 1:01 sergei comp home net:/ibm/home/sergei>
".

On MEPIS/Ubuntu there are (at least) two files with libXrender basename:

1) /usr/X11R6/lib/libXrender.a :

"
mepis1:/mnt/hdd2/sergei> nm -D -A -C /usr/X11R6/lib/libXrender.a
nm: Xrender.o: No symbols
mepis1:/mnt/hdd2/sergei>
";

2) /usr/lib/libXrender.so :

"
mepis1:/mnt/hdd2/sergei> nm -D -A -C /usr/lib/libXrender.so | grep XRenderFindDisplay
/usr/lib/libXrender.so:00005a97 T XRenderFindDisplay
mepis1:/mnt/hdd2/sergei>  
".

So, the second file has the needed resolution.

I added pre_make_sub for 'pango' target which replaces in every Makefile

X_LIBS =  -L/usr/X11R6/lib -lX11

with

X_LIBS = -L/usr/lib -L/usr/X11R6/lib -lX11
.

Please pay attention that '-L/usr/lib' comes before '-L/usr/X11R6/lib' -
otherwise it doesn't work - I'm not quite sure why.

So, my main question:

is it a flaw in 'configure' of 'pango' or in directory structure and
library organization of MEPIS/Ubuntu ?

Thanks,
  Sergei.

Applications From Scratch: http://appsfromscratch.berlios.de/

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



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