Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

QJsonObject: No such file or directory



  • qt5 in ubuntu16.04,
    qmake -v
    QMake version 3.0
    Using Qt version 5.5.1 in /usr/lib/x86_64-linux-gnu

    locate QJsonObject
    /usr/include/x86_64-linux-gnu/qt5/QtCore/QJsonObject

    ../../include/NSUtility/NSJsonConvert.h:9:23: fatal error: QJsonObject: No such file or directory
    #include <QJsonObject>
    ^
    compilation terminated.
    Makefile:227: recipe for target 'NSJsonConvert.o' failed
    make[1]: *** [NSJsonConvert.o] Error 1
    make[1]: Leaving directory '/home/xinghai/workspace/netSCADA/code/Common/Utility'
    Makefile:154: recipe for target 'sub-Common-Utility-make_first' failed
    make: *** [sub-Common-Utility-make_first] Error 2

    thank you in advance. ~~~~~~


  • Moderators

    When NSJsonConvert is being compiled, the compiled does not have QJsonObject header included. Do you build using qmake? Can we see the .pro file?


Log in to reply