[vtkusers] Linux Compiling Error
Arnolfo Marciales
marciale at ula.ve
Thu Sep 7 18:25:07 EDT 2006
Hi i´m new in this forum, i wrote an app in Vtk 5.0.1 and Qt 4.1 in Visual
Studio 2003, and everything goes fine. I use cmake to generate the project
and i try to use sintax that can compile the same code in Linux
When i use cmake in Linux everything goes fine, but when i run make i get
the following errors:
[root at Beleriand002 MyWork]# make VtkQtMedicalBuilding CXX object
CMakeFiles/VtkQtMedical.dir/main.oIn file included from
/usr/local/Vtk.5.0/vtk/Hybrid/vtk3DSImporter.h:26, from
/usr/local/MyWork/VtkCore.h:4, from
/usr/local/MyWork/VtkExamples.h:4, from
/usr/local/MyWork/Tesis.h:4, from
/usr/local/MyWork/VtkQt.h:5, from
/usr/local/MyWork/main.cxx:2:/usr/local/Vtk.5.0/vtk/Rendering/vtkImporter.h:47:
error: multiple types in one declarationIn file included from
/usr/local/MyWork/VtkExamples.h:4, from
/usr/local/MyWork/Tesis.h:4, from
/usr/local/MyWork/VtkQt.h:5, from
/usr/local/MyWork/main.cxx:2:/usr/local/MyWork/VtkCore.h:185: error:
multiple types in one declarationIn file included from
/usr/local/MyWork/VtkExamples.h:4, from
/usr/local/MyWork/Tesis.h:4, from
/usr/local/MyWork/VtkQt.h:5, from
/usr/local/MyWork/main.cxx:2:/usr/local/MyWork/VtkCore.h:3890:20: warning:
no newline at end of file/usr/local/MyWork/main.cxx:5: error: new types
may not be defined in a return type/usr/local/MyWork/main.cxx:5: error:
two or more data types in declaration of
`main'/usr/local/MyWork/main.cxx:5: error: two or more data types in
declaration of `main'/usr/local/MyWork/main.cxx:5: error: extraneous `int'
ignored/usr/local/MyWork/main.cxx:5: error: `main' must return
`int'make[3]: *** [CMakeFiles/VtkQtMedical.dir/main.o] Error 1make[2]: ***
[CMakeFiles/VtkQtMedical.dir/all] Error 2make[1]: ***
[CMakeFiles/VtkQtMedical.dir/rule] Error 2make: *** [VtkQtMedical] Error 2
There are wo errors:
1.- multiple types in one declarationIn file included
2.- int main has tons of errors (i use events of vtk in C maybe that?)
1.......
#include "vtk3DSImporter.h"
#include "vtkActor.h"
#include "vtkActor2D.h"
#include "vtkAssembly.h"
....
Class ()
{
}
.........
2.
int main( int argc, char** argv )
{
//char *argv2; argv2 = new char[3];
//int argc; argc = 0;
QApplication app( argc, argv );
VtkQt mainwindow;
app.setMainWidget(&mainwindow);
int iRetorna;
mainwindow.show();
iRetorna = app.exec();
return iRetorna;
}
I´m using Red Hat Enterprise Linux WS4. The examples of Vtk and Qt works,
and the Qt Vtk work well, what happened?
I´m new in Linux, and i need some help
thanks
More information about the vtkusers
mailing list