Though, digging into Slicers build system, (it builds VTK with X11 on Mac) this is what you need to set to do so.<div><br></div><div><span class="Apple-style-span" style="font-family: 'Times New Roman'; font-size: medium; "><pre style="word-wrap: break-word; white-space: pre-wrap; ">
CMAKE_SHARED_LINKER_FLAGS:STRING="-Wl,dylib_file,/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib:/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib"</pre><pre style="word-wrap: break-word; white-space: pre-wrap; ">
<span class="Apple-style-span" style="font-family: 'Times New Roman'; white-space: normal; "><pre style="word-wrap: break-word; white-space: pre-wrap; ">CMAKE_EXE_LINKER_FLAGS="-Wl,-dylib_file,/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib:/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib"</pre>
<pre style="word-wrap: break-word; white-space: pre-wrap; "><span class="Apple-style-span" style="font-family: 'Times New Roman'; white-space: normal; "><pre style="word-wrap: break-word; white-space: pre-wrap; ">
VTK_USE_CARBON:BOOL=OFF
VTK_USE_COCOA:BOOL=OFF
VTK_USE_X:BOOL=ON</pre><pre style="word-wrap: break-word; white-space: pre-wrap; ">OPENGL_INCLUDE_DIR:PATH=/usr/X11R6/include</pre></span></pre></span></pre></span><br><div class="gmail_quote">On Tue, Feb 22, 2011 at 8:15 AM, David Partyka <span dir="ltr"><<a href="mailto:david.partyka@kitware.com">david.partyka@kitware.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">VTK should be able to build with X11 or Cocoa but not both. Do you require X11? If not, just build with VTK_USE_COCOA set to ON and VTK_USE_X11 OFF.<div>
<div></div><div class="h5"><br><br><div class="gmail_quote">On Tue, Feb 22, 2011 at 8:10 AM, Brickle Macho <span dir="ltr"><<a href="mailto:michael@borck.id.au" target="_blank">michael@borck.id.au</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi All,<br>
<br>
I have managed to build VTK and run a simple program that renders a<br>
shape and writes some text to a window to convince myself that VTK is<br>
working. Next I have attempted to build PCL+Visualization standalone<br>
which has VTK as a dependency. When I run ccmake I get the following<br>
error as I attempt to configure makefiles:<br>
<br>
[ 73%] Building CXX object<br>
CMakeFiles/pcl_visualization.dir/src/libpcl_visualization/interactor.cpp.o<br>
In file included from<br>
/Users/brickle/Development/source/pcl-core-visualization/src/libpcl_visualization/interactor.cpp:38:<br>
/Users/brickle/Development/source/pcl-core-visualization/include/pcl_visualization/interactor.h:43:42:<br>
error: vtkXRenderWindowInteractor.h: No such file or directory<br>
<br>
I found "vtkXRenderWindowInteractor.h" in my VTK source tree and does<br>
not show up in install directory. I assumed that I probably need to<br>
build VTK with X. Is this a correct assumption? I attempted to<br>
reconfigure/build VTK with the VTK_USE_X option selected and I get the<br>
following error:<br>
<br>
CMake Error at CMake/vtkTestGLX.cmake:212 (file):<br>
file STRINGS file "/System/Library/Frameworks/OpenGL.framework/GL/glx.h"<br>
cannot be read.<br>
Call Stack (most recent call first):<br>
Rendering/CMakeLists.txt:482 (INCLUDE)<br>
<br>
I do have the following directory:<br>
/System/Library/Frameworks/OpenGL.framework/OpenGL but I cannot find<br>
glx.h anywhere on my system.<br>
<br>
I am not sure what to try next, should I<br>
<br>
* Build VTK to use X as well as Cocoa<br>
* Install a different OpenGL framework.<br>
* Modify PCL+Visualization CMakelist.txt (would know where to start)<br>
<br>
Any help would be appreciated. If you need more information please let<br>
me know.<br>
<br>
Regards,<br>
<br>
Brickle<br>
--<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
</blockquote></div><br>
</div></div></blockquote></div><br></div>