Important: Please read the Qt Code of Conduct -

Installing Qt on centos 7 machine, without gui

  • Hi,
    I am trying to do a installation on a centos 7 machine.
    I have the following message

    Note: Also available for Linux: linux-clang linux-icc

    Note: No wayland-egl support detected. Cross-toolkit compatibility disabled.

    WARNING: gperf is required to build QtWebEngine.

    ERROR: The OpenGL functionality tests failed!
    You might need to modify the include and library search paths by editing QMAKE_INCDIR_OPENGL[_ES2],
    QMAKE_LIBDIR_OPENGL[_ES2] and QMAKE_LIBS_OPENGL[_ES2] in the mkspec for your platform.

    I tries this:
    sudo yum install mesa-libGL
    as well as sudo yum install mesa-libGL-devel
    as here,
    "Red Hat does not ship native OpenGL libraries, but does ship the Mesa libraries: an MIT licensed implementation of the OpenGL specification. You can add the Mesa OpenGL runtime libraries on your system by installing the following package:
    [root@host ~]# yum install mesa-libGL
    [root@host ~]# yum install mesa-libGL-devel

    but I have the same error

    Package mesa-libGL-17.2.3-8.20171019.el7.x86_64 already installed and latest version

    Is anyone tried such an installation?

    Thanks, Antonis

  • Moderators

    What is your configure call?

    You can pass -no-gui or -no-opengl flag to configure, if I recall correctly.

  • Hi,
    thanks for the answer.
    I used the following options but with both there are errors, now in compiling
    sudo ./configure -prefix /opt/Qt-2 -no-opengl
    but I had an error related with

    2nd attempt was:
    sudo ./configure -prefix /opt/Qt-3 -platform linux-g++
    but I have the following error:
    In file included from ../../include/QtLocation/5.11.0/QtLocation/private/qgeomap_p.h:1:0,
    from declarativemaps/qdeclarativegeomap_p.h:63,
    from declarativemaps/qdeclarativegeomap.cpp:37:
    ../../include/QtLocation/5.11.0/QtLocation/private/../../../../../src/location/maps/qgeomap_p.h:174:18: warning: ‘QGeoMapPrivate’ is already a friend of ‘QGeoMap’ [enabled by default]
    friend class QGeoMapPrivate;
    /QtCore/../../src/corelib/kernel/qobject.h:308:13: note: template argument deduction/substitution failed:
    declarativemaps/qdeclarativegeomap.cpp:723:111: note: mismatched types ‘const typename QtPrivate::FunctionPointer<Func>::Object*’ and ‘QPointer<QGeoMap>’
    connect(m_map, &QGeoMap::cameraCapabilitiesChanged, this, &QDeclarativeGeoMap::onCameraCapabilitiesChanged);
    make[3]: *** [.obj/qdeclarativegeomap.o] Error 1
    make[3]: Leaving directory /opt/qt-everywhere-src-5.11.0/qtlocation/src/location' make[2]: *** [sub-location-make_first] Error 2 make[2]: Leaving directory/opt/qt-everywhere-src-5.11.0/qtlocation/src'
    make[1]: *** [sub-src-make_first] Error 2
    make[1]: Leaving directory `/opt/qt-everywhere-src-5.11.0/qtlocation'
    make: *** [module-qtlocation-make_first] Error 2

    Any ideas? Should I use a seperate question for that?

    Br, Antonis

  • Moderators

    1. Don't configure with root permissions. Don't compile with root permissions, either. You can use root to make install later.
    2. Use newer Qt (5.11.2). This QGeo stuff is a bug. I'm not sure if it was fixed, but there is a chance it was. Alternatively, add -skip qtlocation to your configure call.

  • Hi,
    for 1, I downloaded the source in a directory that needs permission, and I did that due to disk limitations. That's why I followed the quick (and not so good) way to use sudo. Thanks for the tip.
    Also thanks for the fix. Meanwhile I upgraded g++ version (now gcc-5.3.1) and now it compiles OK. Is it safe to proceed with that way? no newer version for qt and no -skip qtlocation flag in configure (I think that it is OK, but I mention this also for the future reader of the thread as an alternative option).

  • Moderators

    Yep, that's OK.

Log in to reply