compiling VTK 2.3 on Red Hat 6.0

Todd Small tas at astro.caltech.edu
Tue Jun 29 03:09:26 EDT 1999


Hi!

I'm having difficulty compiling VTK 2.3 on Red Hat 6.0 (actually,
Linux-Mandrake 6.0, which is built on Red Hat 6.0).  Surprisingly
enough, I have followed the instructions in the VTK-Linux-HOWTO file,
but the compilation fails on practically the first step:

cd wrap;        make - all
make[1]: Entering directory `/usr/src/vtk/wrap'
gcc -O2  -fPIC -D_HP_NO_FAST_MACROS -DHAVE_LIMITS_H     -DHAVE_UNISTD_H 
-I. -I/usr/src/RPM/SOURCES/tk8.0.4/generic
-I/usr/src/RPM/SOURCES/tcl8.0.4/generic -I/usr/include/GL
-DVTK_USE_OGLR   -I/usr/X11R6/include -I./../graphics -DVTK_USE_GRAPHICS
-I./../imaging -DVTK_USE_IMAGING -I./../patented -DVTK_USE_PATENTED
-I./../contrib -DVTK_USE_CONTRIB  -I. -c -o vtkParse.o ./vtkParse.tab.c
-lm
pgcc: cannot specify -o with -c or -S and multiple compilations
make[1]: *** [vtkParse.o] Error 1
make[1]: Leaving directory `/usr/src/vtk/wrap'
make: *** [build_wrap] Error 2

As far as I can gather, the compiler (pgcc-2.91.66 based on egcs-1.1.2)
is objecting to the final "-lm".  If I (perhaps unwisely) simply remove
the "-lm" by hand from the makefile, then I obtain the following error:

gcc -O2  -fPIC -D_HP_NO_FAST_MACROS -DHAVE_LIMITS_H     -DHAVE_UNISTD_H 
-I. -I/usr/src/RPM/SOURCES/tk8.0.4/generic
-I/usr/src/RPM/SOURCES/tcl8.0.4/generic -I/usr/include/GL
-DVTK_USE_OGLR   -I/usr/X11R6/include -I./../graphics -DVTK_USE_GRAPHICS
-I./../imaging -DVTK_USE_IMAGING -I./../patented -DVTK_USE_PATENTED
-I./../contrib -DVTK_USE_CONTRIB  -I. -c -o vtkParse.o ./vtkParse.tab.c
In file included from vtkParse.y:813:
lex.yy.c:45: initializer element for `yyin' is not constant
lex.yy.c:45: initializer element for `yyout' is not constant
make: *** [vtkParse.o] Error 1

I would be grateful for any suggestions about how to fix these problems.

Thanks in advance,

Todd Small


-----------------------------------------------------------------------------
This is the private VTK discussion list.  Please keep messages on-topic.
Check the FAQ at: <http://www.automatrix.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at gsao.med.ge.com>.  For help, send message body containing
"info vtkusers" to the same address.     Live long and prosper.
-----------------------------------------------------------------------------





More information about the vtkusers mailing list