[Paraview] Compiling without X11 libraries

pat marion pat.marion at kitware.com
Wed Feb 24 15:33:26 EST 2010


Sorry I misread your email, you don't want to create X11 windows at all.
You want to do pure osmesa.  So then you'll be all set if you follow the
hacks I describe.  By the way, when I compile osmesa, for pure offscreen, I
just run 'make linux-osmesa' and the result is libOSMesa.so and libGLU.so.

Pat

On Wed, Feb 24, 2010 at 3:29 PM, pat marion <pat.marion at kitware.com> wrote:

> Hi Ken,
>
> Below is copy and paste from a previous email where I answered a similar
> question off-list (your question is a little different because you want to
> use Mesa3D to create windows).  Unfortunately you can't do this without some
> small hacks to the cmakelists.  I think the important part for you is in the
> last paragraph.
>
> ----------
>
> Using true offscreen means using vtkOSOpenGLRenderWindow and not
> vtkXOpenGLRenderWindow.  Which one is used depends on whether or not
> VTK_USE_OSMESA is defined in $build_dir/VTK/vtkToolkits.h.
>
> VTK_USE_OSMESA is defined when:
>
>   * OPENGL_gl_LIBRARY is set to the empty string
>   * VTK_USE_X is OFF
>   * VTK_OPENGL_HAS_OSMESA is true
>
> If the platform is Linux, and cmake is able to locate X11 libraries &
> headers, then cmake will force VTK_USE_X to ON.  You must hack
> VTK/CMake/vtkUseX.cmake to set it to OFF.
>
> Look at the bottom of $build_dir/VTK/vtkToolkits.h to make sure that you
> have successfully defined VTK_USE_OSMESA.
>
> If you are doing a shared build, and OPENGL_gl_LIBRARY is the empty string,
> then you will get link errors because of some changes that were introduced
> after the transitive linking patch last June.  To avoid that, you need to
> change all instances of ${OPENGL_gl_LIBRARY} to ${OSMESA_LIBRARY} in all
> CMakeLists.txt except for VTK/Rendering/CMakeLists.txt or
> VTK/CMakeLists.txt.
>
>
> Pat
>
>
> On Wed, Feb 24, 2010 at 3:10 PM, Moreland, Kenneth <kmorel at sandia.gov>wrote:
>
>>  I do have PARAVIEW_BUILD_GT_GUI off, but I still need rendering.  I
>> still need to create OpenGL windows, but I will only ever do it through
>> OSMesa, never through X11.
>>
>> -Ken
>>
>>
>>
>> On 2/24/10 1:02 PM, "Dave Partyka" <dave.partyka at kitware.com> wrote:
>>
>> I am not sure about ParaView but in VTK if you turn rendering off you
>> should be able to do this. Have you tried turning PARAVIEW_BUILD_QT_GUI off?
>> I do that when I generate the command line tools package on Mac OSX.
>>
>> On Wed, Feb 24, 2010 at 2:40 PM, Moreland, Kenneth <kmorel at sandia.gov>
>> wrote:
>>
>> Is there any way to compile ParaView without any X11 libraries at all?  I
>> compiled OSMesa support for Mesa 3D and tried to link that, but when I link
>> I am missing a bunch of glX* symbols.  I think that in order to build these
>> functions for Mesa, I need an X11 library, which gets me back to the dilemma
>> of what if you have no libraries?
>>
>> -Ken
>>
>>    ****      Kenneth Moreland
>>     ***      Sandia National Laboratories
>> ***********
>> *** *** ***  email: kmorel at sandia.gov <http://kmorel@sandia.gov>
>> **  ***  **  phone: (505) 844-8919
>>     ***      web:   http://www.cs.unm.edu/~kmorel<http://www.cs.unm.edu/%7Ekmorel>
>>
>>
>> _______________________________________________
>> Powered by www.kitware.com <http://www.kitware.com>
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the ParaView Wiki at:
>> http://paraview.org/Wiki/ParaView
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.paraview.org/mailman/listinfo/paraview
>>
>>
>>
>>
>>
>>    ****      Kenneth Moreland
>>     ***      Sandia National Laboratories
>> ***********
>> *** *** ***  email: kmorel at sandia.gov
>> **  ***  **  phone: (505) 844-8919
>>     ***      web:   http://www.cs.unm.edu/~kmorel<http://www.cs.unm.edu/%7Ekmorel>
>>
>>
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the ParaView Wiki at:
>> http://paraview.org/Wiki/ParaView
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.paraview.org/mailman/listinfo/paraview
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20100224/6c67a139/attachment-0001.htm>


More information about the ParaView mailing list