Cmake error: QGLWidget: No such file or directory



  • I am using Qt5 and I am trying to implement a QGLWidget. When I run make after I have configured cmake I get the following error:

    QGLWidget: No such file or directory

    My CMakeList.txt file includes the following:

    cmake_minimum_required(VERSION 2.8)

    set(CMAKE_INCLUDE_CURRENT_DIR ON)

    set(CMAKE_AUTOMOC ON)

    set(QT_USE_QTOPENGL TRUE)

    find_package(Qt5Widgets)

    find_package(Qt5OpenGL)

    find_package(OpenGL REQUIRED)

    qt5_use_modules(myprogram Widgets)


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.