Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 283339

Summary: cross-compiling gpe-base/libgpewidget-0.117-r1 fails due to missing '-lGL' linker flag
Product: Gentoo Linux Reporter: Christopher Friedt <chrisfriedt>
Component: [OLD] UnspecifiedAssignee: GPE Desktop project <gpe>
Status: RESOLVED CANTFIX    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 283348    
Attachments: build.log

Description Christopher Friedt 2009-08-31 16:01:50 UTC
Check out the attached log. After the build failed, I went into the source directory, ran the last command, appending -lGL, and it worked without a problem.

I believe that somehow the pkg-config settings or dependent library settings are not being pulled in properly when linking to libcairo. libcairo itself does not depend on GL, but libcairo-glx does. In this case, however, the linker was complaining about the GL reference made by libglitz, which is a dependency of libcairo. 

The only thing I can really suggest, without hacking too much at the libgpewidget code itself, is to use some sort of 

package_has_use cairo opengl

check, and use append-ldflags "-lGL" in that case.

C



Reproducible: Always

Steps to Reproduce:
1.cross-compile libgpewidget-0.117-r1
2.
3.
Comment 1 Christopher Friedt 2009-08-31 16:02:10 UTC
Created attachment 202812 [details]
build.log
Comment 2 Christopher Friedt 2009-08-31 16:31:40 UTC
for the mean time, I've just manually set LDFLAGS="..." before calling emerge, and that also works. 
Comment 3 Christopher Friedt 2009-08-31 17:51:29 UTC
Another potential solution is to just add -lGL to cairo.pc when it is built with USE=opengl . 
Comment 4 Angelo Arrifano (RETIRED) gentoo-dev 2009-09-04 15:25:50 UTC
Sorry, I nearly missed this one.

Which version and use flags are you using for cairo, glitz and gtk+ ?

Native compiling of USE="cairo" libgpewidget is fine.

x11-libs/gtk+-2.14.7-r2  USE="X cups jpeg jpeg2k tiff vim-syntax -debug -doc -xinerama"
 x11-libs/cairo-1.8.8  USE="X cleartype glitz opengl svg xcb -debug -directfb -doc"
media-libs/glitz-0.5.6

Afaik, libGL should not be linked into gtk+ much less into libgpewidget.

Also, -lGL is present on my glitz-glx.pc
so either pkgconfig is failing on cross-compilations
or (I bet) your gtk+ is broken.


Comment 5 Christopher Friedt 2009-09-04 16:17:50 UTC
media-libs/glitz-0.5.6
x11-libs/cairo-1.8.8 X cleartype directfb glitz opengl svg xcb
x11-libs/gtk+-2.16.5 X jpeg jpeg2k tiff xinerama -cups -debug -doc -test -vim-syntax

It seems like the only difference in our versions is gtk+ - it could be the problem, I suppose. 
Comment 6 Angelo Arrifano (RETIRED) gentoo-dev 2009-09-22 21:18:42 UTC
Sorry, I can't reproduce it. Since the problem isn't on gpe-ownerinfo, I'm
going to close as cantfix.