Tag: qmake

未定义的引用vtable。 试图编译一个Qt项目

我使用的是Code :: Blocks 8.02和mingw 5.1.6编译器。 编译我的Qt项目时出现这个错误: C:\ Documents and Settings \ The Fuzz \ Desktop \ GUI \ App_interface.cpp | 33 |对AddressBook的vtable的未定义引用 文件AddressBook.h: #ifndef ADDRESSBOOK_H #define ADDRESSBOOK_H #include <QWidget> class QLabel; class QLineEdit; class QTextEdit; class AddressBook : public QWidget { Q_OBJECT public: AddressBook(QWidget *parent = 0); private: QLineEdit *nameLine; QTextEdit *addressText; }; #endif 文件AddressBook.cpp: […]

如何添加“-std = c + + 11”到由qmake生成的生成文件?

我正在开发一个Qt程序。 它的makefile是从.pro文件自动生成的。 我需要使用一些需要为g ++设置-std = c ++ 11标志的代码。 .pro应该在哪里添加这个标志? (只改变Makefile将不会工作,因为它被新生成的,每次我build立项目覆盖)。