[vtkusers] new user attempting install on mac OSX

Tobias tobias.straub at lmu.de
Thu Apr 17 07:26:08 EDT 2003


>
> At what stage is it going wrong? Did you compile VTK for Carbon or  
> Cocoa? (I've yet to try it for Cocoa - that's one of my next  
> projects...) Did you eradicate all mention of X11 lib and include  
> paths from your CMakeCache.txt? Are you using gcc3 or gcc2? OSX10.1 or  
> 10.2? Have you got Aqua Tkinter in your Python framework? (Try  
> starting python, then type "import Tkinter".) Have you got the Python  
> interpreter application, so the tk windows have a genuine OSX app to  
> work within?
>
> Bye!
>
so i followed the mayavi build instructions. everything went fine. i  
tested vtk-usage using mayavi's included python test-script. fine. then  
when i start mayavi (whatever way) i get a segmentation fault.
btw: python is working with vtk quite well (not perfect) esp. the  
renderinteractor seems to have probs with aqua tkinter.

but i'm not so much into python/vtk. prefer tcl. and i also tried  
cocoa. which works great for me. but i do a separte build with static  
libraries for cocoa. the other build is for carbon/java/python/tcl with  
shared libs.

in the carbon/python/tcl/java build i have the following settings  
regarding X11:

//X11 extra flags.
CMAKE_X_CFLAGS:STRING=-I/usr/X11R6/include

//Libraries and options used in X11 programs.
CMAKE_X_LIBS:STRING=-lSM;-lICE;/usr/X11R6/lib/libX11.a;/usr/X11R6/lib/ 
libXext.a

//What is the path where the file GL/gl.h can be found
OPENGL_INCLUDE_DIR:PATH=/usr/X11R6/include

//OpenGL lib for OSX
OPENGL_gl_LIBRARY:STRING=-framework OpenGL

//AGL lib for OSX
OPENGL_glu_LIBRARY:STRING=-framework AGL

//Build classes for the X11 window system.
VTK_USE_X:BOOL=OFF

//What is the path where the file X11/X.h can be found
X11_X11_INCLUDE_PATH:PATH=/usr/X11R6/include

//Where can the X11 library be found
X11_X11_LIB:FILEPATH=/usr/X11R6/lib/libX11.a

//Where can the Xext library be found
X11_Xext_LIB:FILEPATH=/usr/X11R6/lib/libXext.a

//What is the path where the file X11/Xlib.h can be found
X11_Xlib_INCLUDE_PATH:PATH=/usr/X11R6/include

//What is the path where the file X11/Xutil.h can be found
X11_Xutil_INCLUDE_PATH:PATH=/usr/X11R6/include

//Dependencies for the target
vtkRendering_LIB_DEPENDS:STATIC=vtkGraphics;vtkImaging;vtkftgl;vtkfreety 
pe;-framework AGL;-framework  
OpenGL;-lSM;-lICE;-lSM;-lICE;/usr/X11R6/lib/libX11.a;/usr/X11R6/lib/ 
libXext.a;/usr/X11R6/lib/libX11.a;/usr/X11R6/lib/libXext.a;-framework  
Carbon;

//Dependencies for the target
vtkftgl_LIB_DEPENDS:STATIC=-framework AGL;-framework  
OpenGL;-lSM;-lICE;-lSM;-lICE;-lSM;-lICE;/usr/X11R6/lib/libX11.a;/usr/ 
X11R6/lib/libXext.a;/usr/X11R6/lib/libX11.a;/usr/X11R6/lib/libXext.a;/ 
usr/X11R6/lib/libX11.a;/usr/X11R6/lib/libXext.a;vtkfreetype;


.. so you see the paths to all the xlibs adn includes is still in the  
cmake.cache but i guess the point is to set VTK_USE_X:BOOL=OFF in order  
to link against the framework opengl instead of X11s gl.h.
for the rest: i'm using gcc3, osx 10.2.5. i have aqua tkinter in the  
python framework and that works. and also the python interpreter.

basically i's prefer to develop in cocoa environment. but for rapid  
testing of pipelines etc.. i prefer TCL as the cocoa compilation takes  
too much time for quickly setting up things. and i'm not expert enough  
to build something like mayavi in cocoa.

Tobias




More information about the vtkusers mailing list