[vtkusers] Undefined reference to Mesa

Kevin H. Hobbs hobbsk at ohiou.edu
Tue Apr 6 07:48:39 EDT 2010


On 04/06/2010 07:10 AM, Hassan Amin wrote:
> I am using cmake. I build Mesa7.6.1 myself, and vtk 5.0.2 myself as
> well. I successfully built vtk with offscreen rendering using osmesa.
> But when I build my application using osmesa I run into these linking
> errors. My application uses a number of libraries including vtk, vxl,
> and itk.
>
>   

Please use your e-mail program's "Reply All" function or add
vtkusers at vtk.org to the list of recipients when you respond to e-mail
from the list. That way the entire community can help.

What are the values of the CMake variables :

OPENGL_INCLUDE_DIR
OPENGL_gl_LIBRARY
OPENGL_glu_LIBRARY
VTK_OPENGL_HAS_OSMESA
OSMESA_INCLUDE_DIR
OSMESA_LIBRARY
VTK_USE_RPATH

in your VTK CMakeCache.txt?

Can you share the CMakeLists.txt file for your application?

I link against VTK with OSMesa with a CMakeLists.txt file that looks like this :


cmake_minimum_required(VERSION 2.4)

PROJECT( series )

FIND_PACKAGE(VTK REQUIRED)
IF(NOT VTK_USE_RENDERING)
  MESSAGE(FATAL_ERROR "Example ${PROJECT_NAME} requires VTK_USE_RENDERING.")
ENDIF(NOT VTK_USE_RENDERING)
INCLUDE(${VTK_USE_FILE})

ADD_EXECUTABLE( five_views_Npoly_1image five_views_Npoly_1image.cxx )
TARGET_LINK_LIBRARIES( five_views_Npoly_1image vtkImaging vtkIO vtkCommon
        vtkRendering vtkVolumeRendering vtkHybrid )




-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 261 bytes
Desc: OpenPGP digital signature
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100406/b0cfcc3b/attachment.pgp>


More information about the vtkusers mailing list