[vtkusers] problems compiling VTK with Tcl/Tk
Robert S Laramee
laramee at vrvis.at
Fri Oct 29 09:21:46 EDT 2004
Dear Mathieu and Fellow VTK Users,
Thanks for your support thus far.
Ok, now i've got the VTK compiling
with Tcl/Tk just fine. However,
now i'm running into problems at
run-time. i have the following
paths set up:
BUILD_EXAMPLES ON
BUILD_SHARED_LIBS OFF
CMAKE_BACKWARDS_COMPATIBILITY 1.6
CMAKE_BUILD_TYPE
CMAKE_INSTALL_PREFIX /home/larameer/evaluation/vtk/vtk-src-unix
TCL_INCLUDE_PATH /home/larameer/tcl/tcl8.4.7/unix/include
TCL_LIBRARY /home/larameer/tcl/tcl8.4.7/unix/lib/libtcl8.4.so
TK_INCLUDE_PATH /home/larameer/tcl/tk8.4.7/unix/include
TK_LIBRARY /home/larameer/tcl/tk8.4.7/unix/lib/libtk8.4.so
VTK_DATA_ROOT /home/larameer/evaluation/vtk/VTKData
VTK_USE_HYBRID ON
VTK_USE_PARALLEL ON
VTK_USE_PATENTED ON
VTK_USE_RENDERING ON
VTK_WRAP_JAVA OFF
VTK_WRAP_PYTHON OFF
VTK_WRAP_TCL ON
Now, when i try to run an Tcl/Tk example, i run
into the following error:
--- BEGIN ERROR ---
[larameer at lnxc25 vtk-src-unix]$ cd Examples/Tutorial/Step1/
[larameer at lnxc25 Step1]$ cd Tcl/
[larameer at lnxc25 Tcl]$ /home/larameer/evaluation/vtk/vtk-src-unix/bin/vtk
Cone.tcl
Application initialization failed: Can't find a usable tk.tcl in the
following directories:
/home/larameer/tcl/tcl8.4.7/unix/lib/tk8.4
/home/larameer/evaluation/vtk/vtk-src-unix/lib/tk8.4
/home/larameer/evaluation/vtk/lib/tk8.4
/home/larameer/evaluation/vtk/vtk-src-unix/library
/home/larameer/evaluation/vtk/library
/home/larameer/evaluation/vtk/tk8.4.7/library
/home/larameer/evaluation/tk8.4.7/library
This probably means that tk wasn't installed properly.
Error in startup script: can't find package vtk
while executing
"package require vtk"
(file "Cone.tcl" line 12)
--- END ERROR ---
Any idea(s) how to fix this problem?
Now, if i manually look into the first directory:
/home/larameer/tcl/tk8.4.7/unix/lib/tk8.4
i can see a tk.tcl file. Also, i'm not sure
i understand where all these paths are
coming from, for example:
/home/larameer/evaluation/vtk/vtk-src-unix/lib/tk8.4
/home/larameer/evaluation/vtk/lib/tk8.4
/home/larameer/evaluation/vtk/vtk-src-unix/library
/home/larameer/evaluation/vtk/library
/home/larameer/evaluation/vtk/tk8.4.7/library
/home/larameer/evaluation/tk8.4.7/library
Because, i never gave these paths to ccmake.
i installed tcl/tk in a separate directory
from the vtk.
Thanks again for the help thus far!
-cheers, bob
On Thursday 28 October 2004 05:26 pm, Mathieu Malaterre wrote:
> Robert,
>
> Change
>
> > TCL_LIBRARY /home/larameer/tcl/tcl8.4.7/unix/lib
> > TK_LIBRARY /home/larameer/tcl/tk8.4.7/unix/lib
>
> into
>
> TCL_LIBRARY
> /home/larameer/tcl/tcl8.4.7/unix/lib/libtcl.a TK_LIBRARY
> /home/larameer/tcl/tk8.4.7/unix/lib/libtk.a
>
> (or .so)
>
> HTH
> Mathieu
>
> Robert S Laramee wrote:
> > Dear Fellow VTK Users,
> >
> > i'm having a problem compiling the VTK with
> > Tcl/Tk. i can compile and run the demo
> > programs just fine without Tcl/Tk.
> >
> > i've downloaded and installed Tcl and
> > Tk v 8.4.7. i've run ccmake and added
> > the Tcl/Tk include directories as follows:
> >
> > BUILD_EXAMPLES ON
> > BUILD_SHARED_LIBS OFF
> > CMAKE_BACKWARDS_COMPATIBILITY 1.6
> > CMAKE_BUILD_TYPE
> > CMAKE_INSTALL_PREFIX
> > /home/larameer/evaluation/vtk/vtk-src-unix TCL_INCLUDE_PATH
> > /home/larameer/tcl/tcl8.4.7/unix/include TCL_LIBRARY
> > /home/larameer/tcl/tcl8.4.7/unix/lib TK_INCLUDE_PATH
> > /home/larameer/tcl/tk8.4.7/unix/include TK_LIBRARY
> > /home/larameer/tcl/tk8.4.7/unix/lib VTK_DATA_ROOT
> > /home/larameer/evaluation/vtk/VTKData VTK_USE_HYBRID ON
> > VTK_USE_PARALLEL ON
> > VTK_USE_PATENTED ON
> > VTK_USE_RENDERING ON
> > VTK_WRAP_JAVA OFF
> > VTK_WRAP_PYTHON OFF
> > VTK_WRAP_TCL ON
> >
> > And ccmake generates the makefiles without
> > reporting any errors. However, i get a problem
> > compiling the VTK. It compiles for quite awhile,
> > (~15 minutes) and then run into the following
> > problem:
> >
> > ...
> > Building object file vtkPatentedInstantiator.o...
> > Building static library
> > /home/larameer/evaluation/vtk/vtk-src-unix/bin/libvtkPatented.a.../home/l
> >arameer/evaluation/vtk/vtk-src-unix/Parallel: building default_target
> > Building dependencies. cmake.depends...
> > Building object file vtkBranchExtentTranslator.o...
> > Building object file vtkCollectPolyData.o...
> > Building object file vtkCommunicator.o...
> > Building object file vtkCompositeManager.o...
> >
> > (more classes) ...
> >
> > Building object file vtkTreeCompositer.o...
> > Building object file vtkSharedMemoryCommunicator.o...
> > Building object file vtkThreadedController.o...
> > Building object file vtkParallelInstantiator.o...
> > Building static library
> > /home/larameer/evaluation/vtk/vtk-src-unix/bin/libvtkParallel.a.../home/l
> >arameer/evaluation/vtk/vtk-src-unix/Wrapping/Tcl: building default_target
> > Building dependencies. cmake.depends...
> > Building executable /home/larameer/evaluation/vtk/vtk-src-unix/bin/vtk...
> > /home/larameer/tcl/tcl8.4.7/unix/lib: file not recognized: Is a directory
> > collect2: ld returned 1 exit status
> > make[3]: *** [/home/larameer/evaluation/vtk/vtk-src-unix/bin/vtk] Error 1
> > make[2]: *** [default_target] Error 2
> > make[1]: *** [default_target_Wrapping_Tcl] Error 2
> > make: *** [default_target] Error 2
> > [larameer at lnxc25 vtk-src-unix]$
> >
> > Any hints/suggestions would be greatly appreciated!
> >
> > -cheers, bob
--
Robert S. Laramee
tel: +43 (316) 787-1740
fax: +43 (316) 787-777
http://www.VRVis.at/ar3/pr2/
John Kerry for President: http://www.johnkerry.com/
More information about the vtkusers
mailing list