我尝试编写一个简单的qt应用程序,当我尝试编译它时出现此错误
#include <QApplication>
#include <QTextEdit>
int main(int argv, char **args)
{
QApplication app(argv, args);
QTextEdit textEdit;
textEdit.show();
return app.exec();
}
_
qmake file.cpp
/home/j/qtf.cpp:4: Extra characters after test expression.
/home/j/qtf.cpp:6: Extra characters after test expression.
/home/j/qtf.cpp:8: Extra characters after test expression.
/home/j/qtf.cpp:11: Extra characters after test expression.
错误在哪里
答案 0 :(得分:3)
为了编译您的应用程序,您必须:
要执行这些步骤,只需调用相应的命令:
qmake -project (generates project file)
qmake (generates makefile)
make (build the project)