Important: Please read the Qt Code of Conduct -

Install Qt5 with EGL for an Embedded System, not GLX.

  • Hi,
    I am building Qt5 with an OpenEmbedded ( build environment for a TI am335x armv7 board using a gcc linaro v4.9 toolchain.

    I am able to build, compile, and install every Qt5 package I need... from qtbase and qtdeclarative to qtwebkit. However, here recently, when I try to run any QtQML app, I receive the following error message on my target hardware:

    • gbm_create_device: invalid fd: -1
      libEGL warning: GLX: failed to load GLX
      Could not initialize egl display

    I do not need GLX because I do not need a initialize OpenGL to an X Window System. I want to use EGL to initialize OpenGL, OpenGL ES1, and OpenGL ES2 to a Window System.
    How do I verify that my Qt packages are configuring, compiling, and installing with EGL and not GLX?

    Here is my configuration statement. As you can see, I have set to configure with items like opengl, eglfs, no-x, etc...

    • -opensource -confirm-license
      -sysroot ${STAGING_DIR_TARGET}
      -prefix ${OE_QMAKE_PATH_PREFIX}
      -bindir ${OE_QMAKE_PATH_BINS}
      -libdir ${OE_QMAKE_PATH_LIBS}
      -datadir ${OE_QMAKE_PATH_DATA}
      -sysconfdir ${OE_QMAKE_PATH_SETTINGS}
      -docdir ${OE_QMAKE_PATH_DOCS}
      -headerdir ${OE_QMAKE_PATH_HEADERS}
      -archdatadir ${OE_QMAKE_PATH_ARCHDATA}
      -libexecdir ${OE_QMAKE_PATH_LIBEXECS}
      -plugindir ${OE_QMAKE_PATH_PLUGINS}
      -importdir ${OE_QMAKE_PATH_IMPORTS}
      -qmldir ${OE_QMAKE_PATH_QML}
      -translationdir ${OE_QMAKE_PATH_TRANSLATIONS}
      -testsdir ${OE_QMAKE_PATH_TESTS}
      -examplesdir ${OE_QMAKE_PATH_EXAMPLES}
      -hostbindir ${OE_QMAKE_PATH_HOST_BINS}
      -hostdatadir ${OE_QMAKE_PATH_HOST_DATA}
      -external-hostbindir ${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}
      -platform ${OE_QMAKESPEC}
      -xplatform linux-oe-g++
      -qpa eglfs
      -opengl es2
      -shared \
      -no-mtdev \
      -nomake tests
      -openssl-linked \
      -nomake examples
      -make tools
      -make libs

    Is there another Qt package for Qt command where I need to set to make sure the window systems & OpenGL for Qt are using EGL and -no-glx?

    Because I am using a TI hardware, I am using omap3 pkg to provide the egl, gles1, gles2 libs; the mesa pkg for gl libraries; and the PowerVR SGX series for gpu drivers.

    Maybe a more general question will at least point me in the right direction... What is the different between libEGL and EGL? I understood that EGL and GLX are the initialisms for window systems, but the error message says libEGL is trying to use GLX which makes me think there is a different between libEGL and EGL.

    Any help, suggestions, or general comments will be appreciated.