标题:求助!编译HELLO时候出错!!不胜感谢!!
作者:nanawoaini
日期:2006-03-29 09:39
内容:
我在编译HELLO的时候出现下边问题怎么也解决不了,请各位高手指点一下,先谢过拉!!
执行MAKE后报错如下:
gcc-o counter counter.o main.o mainwindow.o moc_counter.o moc_mainwindow.o-L/armsys2410/qt_x86/qt/lib -lqte
counter.o(.text+0x39): In function `Counter::Counter(QWidget*, char const*)':
: undefined reference to `operator new(unsigned)'
counter.o(.text+0xf5): In function `Counter::Counter(QWidget*, char const*)':
: undefined reference to `operator new(unsigned)'
main.o(.text+0x24): In function `main':
: undefined reference to `operator new(unsigned)'
mainwindow.o(.text+0x8b): In function `MainWindow::MainWindow(QWidget*, char const*)':
: undefined reference to `operator new(unsigned)'
mainwindow.o(.text+0x100): In function `MainWindow::MainWindow(QWidget*, char const*)':
: undefined reference to `operator new(unsigned)'
mainwindow.o(.text+0x175): more undefined references to `operator new(unsigned)' follow
moc_counter.o(.gnu.linkonce.t._ZN7CounterD0Ev+0x28): In function `Counter::~Counter ()':
: undefined reference to `operator delete(void*)'
moc_mainwindow.o(.gnu.linkonce.t._ZN10MainWindowD0Ev+0x28): In function `MainWindow::~MainWindow ()':
: undefined reference to `operator delete(void*)'
/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `operator new[](unsigned)'
/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `cos'
/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `sin'
/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `__cxa_pure_virtual'/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `pow'
/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `operator delete[](void*)'
collect2: ld returned 1 exit status
该如何解决啊!!!
#1 [hanrock 03-29 11:46]
: undefined reference to `operator new(unsigned)'
/armsys2410/qt_x86/qt/lib/libqte.so: undefined reference to `operator new[](unsigned)'
没包含头文件吧,或是编译的库不全
#2 [nanawoaini 03-29 18:38]
还需要哪些库呢?我的qt/lib里只有libqte.so还该加哪些呢,望赐教