[vtkusers] QVTKRenderWindowInteractor crashes under Mac OS X 10.6 + CMake x86_64 issue

Michael Jackson mike.jackson at bluequartz.net
Wed Sep 30 14:23:12 EDT 2009


Send the output from:

file /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
libvtkfreetype.dylib

How you are compiling your project and how 'vtk-cvs-python-carbon' are  
two different things.

My guess is that one is 32 bit and the other is 64 bit. Or 'vtk-cvs- 
python-carbon' is either 32 or 64 bit and your project is Universal  
binary with both 32 and 64 bit binaries.

When you get the warning:
> ld: warning: in /foo/bar/blah, file is not of required architecture

it means there is a mismatch between what you are compiling and what  
you are linking to. So check that all your support libraries (VTK in  
this case) is compiled with the EXACT same archs as your own project.

  You can use the 'file' command to have OS X tell you what archs are  
stored in any file (executable or dylib or static library).

   use "make VERBOSE=1" and carefully inspect the compile flags. On OS  
X 10.5, 32 bit binaries are default. On OS X 10.6 64 bit binaries are  
default. Therefore, if you are on OS X 10.6 and you want to compile a  
32 bit binary then you MUST be able to see the "-arch i386" flag on  
the command line. If you do NOT see that flag then you are compiling a  
64 bit binary.

Next I see that you may be trying to wrap VTK with Python. How is  
Python compiled? Is is Carbon based? If so you may be limited to 32  
bit depending on if Python got rid of Carbon code that would NOT allow  
them to produce a 64 bit binary.

Hope some of that helps;
_________________________________________________________
Mike Jackson                  mike.jackson at bluequartz.net
BlueQuartz Software                    www.bluequartz.net
Principal Software Engineer                  Dayton, Ohio

On Sep 30, 2009, at 2:11 PM, Piotr Byzia wrote:

> On 30.09.2009, at 18:52, Sean McBride wrote:
>
>> On 9/30/09 6:14 PM, Piotr Byzia said:
>>
>>> It seems that i386 is correctly recognized now, however there is
>>> another issue related to Python during the compilation:
>>>
>>> [ 74%] Building CXX object Rendering/CMakeFiles/
>>> vtkRenderingPythonTkWidgets.dir/vtkTkRenderWidgetPython.o
>>> In file included from /Users/piotr/Downloads/VTK/Rendering/
>>> vtkTkRenderWidgetPython.cxx:17:
>>> /Users/piotr/Downloads/VTK/Rendering/vtkTkRenderWidget.cxx: In
>>> function 'int  
>>> vtkTkRenderWidget_MakeRenderWindow(vtkTkRenderWidget*)':
>>> /Users/piotr/Downloads/VTK/Rendering/vtkTkRenderWidget.cxx:1154:
>>> error: invalid conversion from 'void*' to 'OpaqueGrafPtr*'
>>> /Users/piotr/Downloads/VTK/Rendering/vtkTkRenderWidget.cxx:1154:
>>> error:   initializing argument 1 of 'OpaqueWindowPtr*  
>>> GetWindowFromPort
>>> (OpaqueGrafPtr*)'
>>> make[2]: *** [Rendering/CMakeFiles/vtkRenderingPythonTkWidgets.dir/
>>> vtkTkRenderWidgetPython.o] Error 1
>>> make[1]: *** [Rendering/CMakeFiles/vtkRenderingPythonTkWidgets.dir/
>>> all] Error 2
>>> make: *** [all] Error 2
>>>
>>> Is that something wrong with my configuration or is that a known
>>> problem?
>>
>> Yes, this was discussed recently on the vtk-dev list.  You should be
>> able to find it in the archives.  Short version: try VTK from CVS. :)
>>
>> I guess the lesson is that current CMake and VTK are not quite fully
>> compatible with 10.6, you should use the CVS versions.
>
> Correct me if I'm wrong, but there were no follow up on this issue  
> on vtk-dev:
>
> Build files have been written to: /Users/piotr/Downloads/vtk-cvs- 
> python-carbon/Examples/All
> ======== End CMake output ======
> Change Dir: /Users/piotr/Downloads/vtk-cvs-python-carbon/Examples/All
>
> Run Build Command:/usr/bin/make
> Scanning dependencies of target HierarchicalBoxPipeline
> [  3%] Building CXX object AMR/Cxx/CMakeFiles/ 
> HierarchicalBoxPipeline.dir/HierarchicalBoxPipeline.o
> Linking CXX executable /Users/piotr/Downloads/vtk-cvs-python-carbon/ 
> bin/HierarchicalBoxPipeline
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkRendering.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkIO.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkGraphics.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkverdict.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkImaging.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkFiltering.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkCommon.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkDICOMParser.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkNetCDF.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkmetaio.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtksqlite.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkpng.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtktiff.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkzlib.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkjpeg.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkexpat.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtksys.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkftgl.dylib, file is not of required architecture
> ld: warning: in /Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> libvtkfreetype.dylib, file is not of required architecture
> Undefined symbols:
>  "vtkRenderer::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkOutlineCornerFilter::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkRenderWindowInteractor::SetRenderWindow(vtkRenderWindow*)",  
> referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkHierarchicalPolyDataMapper::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>  "vtkDebugLeaksManager::vtkDebugLeaksManager()", referenced from:
>      __static_initialization_and_destruction_0(int, int)in  
> HierarchicalBoxPipeline.o
>  "vtkHierarchicalDataSetGeometryFilter::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkExtractLevel::AddLevel(unsigned int)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkRenderer::ResetCamera()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkContourValues::SetValue(int, double)", referenced from:
>      vtkContourFilter::SetValue(int, double)in  
> HierarchicalBoxPipeline.o
>  "vtkActor::GetProperty()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>  "vtkRenderer::GetActiveCamera()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkCamera::SetFocalPoint(double, double, double)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkCompositeDataPipeline::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>  "vtkActor::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>  "vtkCamera::SetPosition(double, double, double)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkAlgorithm::GetOutputPort(int)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>  "vtkContourFilter::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkCellDataToPointData::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkCamera::SetViewUp(double, double, double)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkExtractLevel::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkDebugLeaksManager::~vtkDebugLeaksManager()", referenced from:
>      ___tcf_1 in HierarchicalBoxPipeline.o
>  "vtkRenderWindowInteractor::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkProperty::SetColor(double, double, double)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>  "vtkShrinkPolyData::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkXMLHierarchicalBoxDataReader::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkRenderWindow::New()", referenced from:
>      _main in HierarchicalBoxPipeline.o
>  "vtkRenderer::AddActor(vtkProp*)", referenced from:
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
>      _main in HierarchicalBoxPipeline.o
> ld: symbol(s) not found
> collect2: ld returned 1 exit status
> make[5]: *** [/Users/piotr/Downloads/vtk-cvs-python-carbon/bin/ 
> HierarchicalBoxPipeline] Error 1
> make[4]: *** [AMR/Cxx/CMakeFiles/HierarchicalBoxPipeline.dir/all]  
> Error 2
> make[3]: *** [all] Error 2
> make[2]: *** [VTKExamples] Error 1
> make[1]: *** [Examples/CMakeFiles/VTKExamplesTarget.dir/all] Error 2
> make: *** [all] Error 2
>
> _______________________________________________
> 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 VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers




More information about the vtkusers mailing list