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

Bug 68926

Summary: cmake use MesaGL by default instead of libGL
Product: Gentoo Linux Reporter: Tom Hosiawa <tomek32>
Component: New packagesAssignee: Lisa Seelye (RETIRED) <lisa>
Status: RESOLVED WONTFIX    
Severity: major    
Priority: High    
Version: unspecified   
Hardware: x86   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Patch to fix opengl library search order in FindOpenGL.cmake
/FindOpenGL.diff

Description Tom Hosiawa 2004-10-25 21:55:31 UTC
cmake searches for MesaGL, then libGL due to the order set in the config file. Therefore, this is always finding MesaGL, instead of /usr/lib/libGL.so which is set by opengl-update.

by changing the order in /usr/share/cmake/Modules/FindOpenGL.cmake, we can fix this

Reproducible: Always
Steps to Reproduce:
Comment 1 Tom Hosiawa 2004-10-25 21:58:33 UTC
Created attachment 42597 [details, diff]
Patch to fix opengl library search order in FindOpenGL.cmake
Comment 2 Seemant Kulleen (RETIRED) gentoo-dev 2004-10-26 19:13:56 UTC
this should probably be sent upstream too
Comment 3 Tom Hosiawa 2004-10-26 19:32:40 UTC
done
http://www.vtk.org/Bug/bug.php?op=show&bugid=1287&pos=0
Comment 4 Lisa Seelye (RETIRED) gentoo-dev 2004-10-27 14:27:17 UTC
re Comment #1, can you post that as a unidiff?
Comment 5 Tom Hosiawa 2004-10-27 16:05:48 UTC
Created attachment 42728 [details, diff]
/FindOpenGL.diff
Comment 6 Lisa Seelye (RETIRED) gentoo-dev 2004-12-14 14:58:17 UTC
Is there some reason to ignore the comment:

  # The first line below is to make sure that the proper headers
  # are used on a Linux machine with the NVidia drivers installed.
  # They replace Mesa with NVidia's own library but normally do not
  # install headers and that causes the linking to
  # fail since the compiler finds the Mesa headers but NVidia's library.
  # Make sure the NVIDIA directory comes BEFORE the others.
  #  - Atanas Georgiev <atanas@cs.columbia.edu>

(from FindOpenGL.cmake)
Comment 7 Tom Hosiawa 2004-12-16 15:48:47 UTC
I'm not sure, maybe it's something to do with gentoo using opengl-update to set the current opengl libraries used. I just know it worked for me.
Comment 8 Lisa Seelye (RETIRED) gentoo-dev 2005-01-11 22:31:19 UTC
I'm going to close this because there's a directive in the program itself not to do what this patch does. Added to that is the fact that you're the only one to report this as an issue.  If more users have this as an issue I'll be more than happy to reopen this bug and commit the patch; but for now I can't justify bloating the portage tree any more than it is already.