0

Main.cpp

#include <QApplication>
int main (int argc, char* argv[]) {
    QApplication app(argc, argv);

    return app.exec();
}

test.pro

SOURCES += \
    main.cpp
greaterThan(QT_MAJOR_VERSION,4) : QT +=widgets

outputs :

在此处输入图像描述

由于“未定义的引用”,我无法编译我的项目,似乎我的编译器没有找到“QApplication”,但我不知道如何解决它。我卸载并重新安装了我的 Qt,但它没有修复它。

4

0 回答 0