[vtkusers] VTK & Qt 4.4.3 on Mac

Michael Jackson mike.jackson at bluequartz.net
Mon Dec 1 10:17:48 EST 2008


I would suggest starting with a clean build directory. VTK 5.2 is  
known to build without problems on OS X 10.5 and 10.4 using the latest  
Xcode distributions for each OS. The only thing you should have to  
change is the VTK_USE_CARBON to ON and the VTK_USE_COCOA to OFF.

Get that to compile. After that successfully compiles then add in the  
VTK_USE_QVTK.

_________________________________________________________
Mike Jackson                  mike.jackson at bluequartz.net
             www.bluequartz.net


On Dec 1, 2008, at 10:08 AM, Arnaud Gelas wrote:

> Hi Elvis,
>
> When I compile with these settings, I got these link errors:
>
>>> VTK_USE_CARBON                ON
>>> VTK_USE_COCOA         OFF
>>> VTK_USE_QVTK                  ON
>>> VTK_USE_X                             OFF
>>>
>>> I get these link errors:
>>>
>>> Linking CXX shared library ../bin/libvtkRendering.dylib
>>> Undefined symbols:
>>> "_aglSwapBuffers", referenced from:
>>>    vtkCarbonRenderWindow::Frame()      in vtkCarbonRenderWindow.o
>>> "_aglDestroyPixelFormat", referenced from:
>>>    vtkCarbonRenderWindowInternal::CreateContext(int, int&, int&,
>>> int&, int&, int&, char const*&)in vtkCarbonRenderWindow.o
>>> "_aglCreateContext", referenced from:
>>>    vtkCarbonRenderWindowInternal::CreateContext(int, int&, int&,
>>> int&, int&, int&, char const*&)in vtkCarbonRenderWindow.o
>>> "_aglErrorString", referenced from:
>>>    aglReportError()     in vtkCarbonRenderWindow.o
>>> "_aglDisable", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglIsEnabled", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglSetInteger", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateAWindow()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglGetCurrentContext", referenced from:
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::IsCurrent()      in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::IsCurrent()      in
>>> vtkCarbonRenderWindow.o
>>> "_aglEnable", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglSetOffScreen", referenced from:
>>>    vtkCarbonRenderWindow::CreateOffScreenWindow(int, int)in
>>> vtkCarbonRenderWindow.o
>>> "_aglChoosePixelFormat", referenced from:
>>>    vtkCarbonRenderWindowInternal::ChoosePixelFormat(int, int, int,
>>> int, int, int, int)in vtkCarbonRenderWindow.o
>>> "_aglDestroyContext", referenced from:
>>>    vtkCarbonRenderWindow::DestroyWindow()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::DestroyOffScreenWindow()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglUpdateContext", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglGetError", referenced from:
>>>    aglReportError()     in vtkCarbonRenderWindow.o
>>> "_aglSetDrawable", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateAWindow()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglSetCurrentContext", referenced from:
>>>    vtkCarbonRenderWindow::DestroyWindow()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateOffScreenWindow(int, int)in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateAWindow()       in
>>> vtkCarbonRenderWindow.o
>>> ld: symbol(s) not found
>>> collect2: ld returned 1 exit status
>>> make[2]: *** [bin/libvtkRendering.5.3.0.dylib] Error 1
>>> make[1]: *** [Rendering/CMakeFiles/vtkRendering.dir/all] Error 2
>>> make: *** [all] Error 2
>
>
>
>
> On Dec 1, 2008, at 10:02 AM, Elvis Dowson wrote:
>
>> Hi Arnaud,
>>                       You need to set VTK_USE_CARBON to ON, then
>> configure. After that, set the VTK_GUI_SUPPORT to ON, then configure,
>> then it will prompt you for the QT version, set it to 4, and then
>> configure and generate the configuration.
>>
>> Best regards,
>>
>> Elvis
>>
>> On Dec 1, 2008, at 6:51 PM, Arnaud Gelas wrote:
>>
>>> Hi guys,
>>>
>>> I have been trying to compile VTK (cvs snapshot), with Qt 4.4.3. I
>>> have successfully managed to compile and use it on linux, win32,
>>> still some minor issues on win64, but I can not figure out what
>>> should the option on Mac. Is there any wiki page that deals with it?
>>> Anyway, I would really appreciate any advice.
>>>
>>> Thanks in advance,
>>> Arnaud
>>>
>>> I have already tried several configurations, but none of them
>>> worked... Every time I have some link errors :-/.
>>>
>>> Note:
>>>
>>> * when I compile with:
>>> VTK_USE_CARBON                OFF
>>> VTK_USE_COCOA         OFF
>>> VTK_USE_QVTK                  ON
>>> VTK_USE_X                             OFF
>>>
>>> I get this link errors:
>>>
>>> Linking CXX shared library ../../bin/libQVTK.dylib
>>> Undefined symbols:
>>> "vtkCarbonRenderWindow::UpdateGLRegion()", referenced from:
>>>    QVTKWidget::DirtyRegionProcessor(OpaqueEventHandlerCallRef*,
>>> OpaqueEventRef*, void*)   in QVTKWidget.o
>>> ld: symbol(s) not found
>>> collect2: ld returned 1 exit status
>>> make[2]: *** [bin/libQVTK.5.3.0.dylib] Error 1
>>> make[1]: *** [GUISupport/Qt/CMakeFiles/QVTK.dir/all] Error 2
>>> make: *** [all] Error 2
>>>
>>> => It seems that QVTK needs CARBON ??
>>>
>>>
>>> * when I compile with:
>>> VTK_USE_CARBON                OFF
>>> VTK_USE_COCOA         ON
>>> VTK_USE_QVTK                  ON
>>> VTK_USE_X                             OFF
>>>
>>> I get this link errors:
>>>
>>> Linking CXX shared library ../../bin/libQVTK.dylib
>>> Undefined symbols:
>>> "vtkCarbonRenderWindow::UpdateGLRegion()", referenced from:
>>>    QVTKWidget::DirtyRegionProcessor(OpaqueEventHandlerCallRef*,
>>> OpaqueEventRef*, void*)   in QVTKWidget.o
>>> ld: symbol(s) not found
>>> collect2: ld returned 1 exit status
>>> make[2]: *** [bin/libQVTK.5.3.0.dylib] Error 1
>>> make[1]: *** [GUISupport/Qt/CMakeFiles/QVTK.dir/all] Error 2
>>> make: *** [all] Error 2
>>>
>>> => It seems that QVTK really needs CARBON ?
>>>
>>> * When I compile with:
>>> VTK_USE_CARBON                ON
>>> VTK_USE_COCOA         OFF
>>> VTK_USE_QVTK                  ON
>>> VTK_USE_X                             OFF
>>>
>>> I get these link errors:
>>>
>>> Linking CXX shared library ../bin/libvtkRendering.dylib
>>> Undefined symbols:
>>> "_aglSwapBuffers", referenced from:
>>>    vtkCarbonRenderWindow::Frame()      in vtkCarbonRenderWindow.o
>>> "_aglDestroyPixelFormat", referenced from:
>>>    vtkCarbonRenderWindowInternal::CreateContext(int, int&, int&,
>>> int&, int&, int&, char const*&)in vtkCarbonRenderWindow.o
>>> "_aglCreateContext", referenced from:
>>>    vtkCarbonRenderWindowInternal::CreateContext(int, int&, int&,
>>> int&, int&, int&, char const*&)in vtkCarbonRenderWindow.o
>>> "_aglErrorString", referenced from:
>>>    aglReportError()     in vtkCarbonRenderWindow.o
>>> "_aglDisable", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglIsEnabled", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglSetInteger", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateAWindow()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglGetCurrentContext", referenced from:
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::IsCurrent()      in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::IsCurrent()      in
>>> vtkCarbonRenderWindow.o
>>> "_aglEnable", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglSetOffScreen", referenced from:
>>>    vtkCarbonRenderWindow::CreateOffScreenWindow(int, int)in
>>> vtkCarbonRenderWindow.o
>>> "_aglChoosePixelFormat", referenced from:
>>>    vtkCarbonRenderWindowInternal::ChoosePixelFormat(int, int, int,
>>> int, int, int, int)in vtkCarbonRenderWindow.o
>>> "_aglDestroyContext", referenced from:
>>>    vtkCarbonRenderWindow::DestroyWindow()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::DestroyOffScreenWindow()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglUpdateContext", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglGetError", referenced from:
>>>    aglReportError()     in vtkCarbonRenderWindow.o
>>> "_aglSetDrawable", referenced from:
>>>    vtkCarbonRenderWindow::UpdateGLRegion()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateAWindow()       in
>>> vtkCarbonRenderWindow.o
>>> "_aglSetCurrentContext", referenced from:
>>>    vtkCarbonRenderWindow::DestroyWindow()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::MakeCurrent()       in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateOffScreenWindow(int, int)in
>>> vtkCarbonRenderWindow.o
>>>    vtkCarbonRenderWindow::CreateAWindow()       in
>>> vtkCarbonRenderWindow.o
>>> ld: symbol(s) not found
>>> collect2: ld returned 1 exit status
>>> make[2]: *** [bin/libvtkRendering.5.3.0.dylib] Error 1
>>> make[1]: *** [Rendering/CMakeFiles/vtkRendering.dir/all] Error 2
>>> make: *** [all] Error 2
>>>






More information about the vtkusers mailing list