[Comm] Ошибки при сборке QT3-приложений
Прокопьев Евгений
=?iso-8859-1?q?john_=CE=C1_rmts=2Edonpac=2Eru?=
Вт Мар 25 13:17:09 MSK 2003
Здравствуйте!
После установки ALM2.2 пытаюсь перенести свой код с QT2 на QT3. Для
просты берем примитивный пример из учебника по QT Designer - Pizza.
К письму приложены pizza.pro и сгенерированный Makefile.
При сборке получаем:
/usr/lib/qt3//bin/uic pizzatestdialogbase.ui -o pizzatestdialogbase.h
g++ -c -pipe -Wall -W -pipe -Wall -O2 -fexpensive-optimizations
-march=i586 -mcpu=i686 -DGLX_GLXEXT_LEGACY -fno-use-cxa-atexit
-fno-exceptions -DQT_NO_DEBUG -I/usr/lib/qt3//mkspecs/default -I.
-I/usr/lib/qt3//include -o main.o main.cpp
g++ -c -pipe -Wall -W -pipe -Wall -O2 -fexpensive-optimizations
-march=i586 -mcpu=i686 -DGLX_GLXEXT_LEGACY -fno-use-cxa-atexit
-fno-exceptions -DQT_NO_DEBUG -I/usr/lib/qt3//mkspecs/default -I.
-I/usr/lib/qt3//include -o pizzatestdialog.o pizzatestdialog.cpp
/usr/lib/qt3//bin/uic pizzatestdialogbase.ui -i pizzatestdialogbase.h -o
pizzatestdialogbase.cpp
g++ -c -pipe -Wall -W -pipe -Wall -O2 -fexpensive-optimizations
-march=i586 -mcpu=i686 -DGLX_GLXEXT_LEGACY -fno-use-cxa-atexit
-fno-exceptions -DQT_NO_DEBUG -I/usr/lib/qt3//mkspecs/default -I.
-I/usr/lib/qt3//include -o pizzatestdialogbase.o pizzatestdialogbase.cpp
/usr/lib/qt3//bin/moc pizzatestdialog.h -o moc_pizzatestdialog.cpp
g++ -c -pipe -Wall -W -pipe -Wall -O2 -fexpensive-optimizations
-march=i586 -mcpu=i686 -DGLX_GLXEXT_LEGACY -fno-use-cxa-atexit
-fno-exceptions -DQT_NO_DEBUG -I/usr/lib/qt3//mkspecs/default -I.
-I/usr/lib/qt3//include -o moc_pizzatestdialog.o moc_pizzatestdialog.cpp
/usr/lib/qt3//bin/moc pizzatestdialogbase.h -o moc_pizzatestdialogbase.cpp
g++ -c -pipe -Wall -W -pipe -Wall -O2 -fexpensive-optimizations
-march=i586 -mcpu=i686 -DGLX_GLXEXT_LEGACY -fno-use-cxa-atexit
-fno-exceptions -DQT_NO_DEBUG -I/usr/lib/qt3//mkspecs/default -I.
-I/usr/lib/qt3//include -o moc_pizzatestdialogbase.o
moc_pizzatestdialogbase.cpp
g++ -o pizza main.o pizzatestdialog.o pizzatestdialogbase.o
moc_pizzatestdialog.o moc_pizzatestdialogbase.o -L/usr/lib/qt3//lib
-L/usr/X11R6/lib -lqt-mt -lXext -lX11 -lm
main.o: In function `main':
main.o(.text+0x20): undefined reference to
`QApplication::QApplication(int &, char **)'
main.o(.text+0x41): undefined reference to
`QApplication::setMainWidget(QWidget *)'
main.o(.text+0x49): undefined reference to `QDialog::exec(void)'
main.o(.text+0x74): undefined reference to
`QApplication::~QApplication(void)'
pizzatestdialog.o: In function `PizzaTestDialog::PizzaTestDialog(QWidget
*, char const *, bool, unsigned int)':
pizzatestdialog.o(.text+0x3b): undefined reference to
`QDate::currentDate(void)'
pizzatestdialog.o(.text+0x4d): undefined reference to
`QDate::dayOfWeek(void) const'
pizzatestdialog.o: In function `PizzaTestDialog::sendOrder(void)':
pizzatestdialog.o(.text+0xb8): undefined reference to
`QString::QString(char const *)'
pizzatestdialog.o(.text+0xc8): undefined reference to
`QMessageBox::information(QWidget *, QString const &, QString const &,
int, int, int)'
...
undefined reference to `QPaintDevice::fontMet(QFont *, int, char const
*, int) const'
moc_pizzatestdialogbase.o(.gnu.linkonce.d.__vt_19PizzaTestDialogBase.12QPaintDevice+0x2c):
undefined reference to `QPaintDevice::fontInf(QFont *, int) const'
moc_pizzatestdialogbase.o: In function `PizzaTestDialogBase type_info
function':
moc_pizzatestdialogbase.o(.gnu.linkonce.t.__tf19PizzaTestDialogBase+0x10):
undefined reference to `QDialog type_info function'
collect2: ld returned 1 exit status
make: *** [pizza] Ошибка 1
--
С уважением, Прокопьев Евгений
----------- следующая часть -----------
An embedded and charset-unspecified text was scrubbed...
Name: pizza.pro
URL: <http://lists.altlinux.org/pipermail/community/attachments/20030325/bd3c92d5/attachment-0004.ksh>
----------- следующая часть -----------
An embedded and charset-unspecified text was scrubbed...
Name: Makefile
URL: <http://lists.altlinux.org/pipermail/community/attachments/20030325/bd3c92d5/attachment-0005.ksh>
Подробная информация о списке рассылки community