<HTML>
<HEAD>
<TITLE>Re: [vtk-developers] Possible correct to OSMESA builds for static</TITLE>
</HEAD>
<BODY>
<FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'>I’m building Mesa myself, so it’s very likely I’ve done it incorrectly. I can’t equally compare with shared builds, since I have used existing OSMesa builds on those platforms. I will attempt a shared build on my mesa build when I have the chance.<BR>
<BR>
<BR>
On 8/23/10 12:15 PM, "Moreland, Kenneth" <<a href="kmorel@sandia.gov">kmorel@sandia.gov</a>> wrote:<BR>
<BR>
</SPAN></FONT><BLOCKQUOTE><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'>I’m way not the expert on this, but I did this recently and I recall that when I built OSMesa static, all the GL functions were included in libOSMesa.a. Thus, you should not need a GL library at all. Has the Mesa build changed recently (like in the last few months)? Are things different when you compile with shared libraries?<BR>
<BR>
-Ken <BR>
<BR>
<BR>
On 8/23/10 12:04 PM, "Fabian, Nathan" <<a href="ndfabia@sandia.gov">ndfabia@sandia.gov</a>> wrote:<BR>
<BR>
</SPAN></FONT><BLOCKQUOTE><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'>Hi,<BR>
<BR>
If I build with OSMESA but VTK_USE_X=false and build static, I get failures<BR>
to link. I believe the problem is in the locations where we link<BR>
OSMESA_LIBRARY, we need to also explicitly link with OPENGL_gl_LIBRARY (to<BR>
be explicit: Utilities/IceT/CMakeLists.txt, VTK/Rendering/CMakeLists.txt,<BR>
and VTK/VolumeRendering/CMakeLists.txt).<BR>
<BR>
Example diff:<BR>
-SET(KIT_LIBS ${KIT_LIBS} ${OSMESA_LIBRARY})<BR>
+SET(KIT_LIBS ${KIT_LIBS} ${OSMESA_LIBRARY} ${OPENGL_gl_LIBRARY})<BR>
<BR>
And similarly for MANGLED_OSMESA_LIBRARY although I haven't tested that.<BR>
<BR>
This is based on my assumption that we'd specify both mesa's GL as the<BR>
gl_LIBRARY as well as the OSMESA library itself in the CMakeCache. If this<BR>
is an incorrect assumption then please ignore me :)<BR>
<BR>
This works for me, but is it a correct change?<BR>
<BR>
Thanks,<BR>
Nathan.<BR>
<BR>
<BR>
_______________________________________________<BR>
Powered by www.kitware.com<BR>
<BR>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a><BR>
<BR>
Follow this link to subscribe/unsubscribe:<BR>
<a href="http://www.vtk.org/mailman/listinfo/vtk-developers">http://www.vtk.org/mailman/listinfo/vtk-developers</a><BR>
<BR>
<BR>
<BR>
</SPAN></FONT></BLOCKQUOTE><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'><BR>
</SPAN></FONT><FONT SIZE="2"><FONT FACE="Consolas, Courier New, Courier"><SPAN STYLE='font-size:10pt'><BR>
**** Kenneth Moreland<BR>
*** Sandia National Laboratories<BR>
*********** <BR>
*** *** *** email: <a href="kmorel@sandia.gov">kmorel@sandia.gov</a><BR>
** *** ** phone: (505) 844-8919<BR>
*** web: <a href="http://www.cs.unm.edu/~kmorel">http://www.cs.unm.edu/~kmorel</a><BR>
</SPAN></FONT></FONT><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'><BR>
<BR>
</SPAN></FONT></BLOCKQUOTE>
</BODY>
</HTML>