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

Errors when generating makefile for cross compile qt from host ubuntu and raspberry pi 4B



  • Howdy,
    I am new to QT and relatively new to rpi. I am having trouble building QT 5.12.6 for cross compile. Have worked through many errors already today and this is as far as I have made it before needing extra help.

    ./configure -sysroot ~/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix ~/raspi/qt5pi -hostprefix ~/raspi/qt5 -no-use-gold-linker -v
    

    Here is my output:

    Build options:
      Mode ................................... release
      Optimize release build for size ........ no
      Building shared libraries .............. yes
      Using C standard ....................... C11
      Using C++ standard ..................... C++1z
      Using ccache ........................... no
      Using gold linker ...................... no
      Using new DTAGS ........................ yes
      Using precompiled headers .............. yes
      Using LTCG ............................. no
      Target compiler supports:
        SSE .................................. SSE2 SSE3 SSSE3 SSE4.1 SSE4.2
        AVX .................................. AVX AVX2
        AVX512 ............................... F ER CD PF DQ BW VL IFMA VBMI
        Other x86 ............................ AES F16C RDRAND SHA
        Intrinsics without -mXXX option ...... yes
      Build parts ............................ libs
    Qt modules and options:
      Qt Concurrent .......................... yes
      Qt D-Bus ............................... yes
      Qt D-Bus directly linked to libdbus .... no
      Qt Gui ................................. yes
      Qt Network ............................. yes
      Qt Sql ................................. yes
      Qt Testlib ............................. yes
      Qt Widgets ............................. yes
      Qt Xml ................................. yes
    Support enabled for:
      Using pkg-config ....................... yes
      udev ................................... no
      Using system zlib ...................... no
    Qt Core:
      DoubleConversion ....................... yes
        Using system DoubleConversion ........ no
      GLib ................................... no
      iconv .................................. yes
      ICU .................................... no
      Tracing backend ........................ <none>
      Logging backends:
        journald ............................. no
        syslog ............................... no
        slog2 ................................ no
      Using system PCRE2 ..................... no
    Qt Network:
      getifaddrs() ........................... no
      IPv6 ifname ............................ no
      libproxy ............................... no
      Linux AF_NETLINK ....................... no
      OpenSSL ................................ no
        Qt directly linked to OpenSSL ........ no
      OpenSSL 1.1 ............................ no
      DTLS ................................... no
      SCTP ................................... no
      Use system proxies ..................... yes
    Qt Gui:
      Accessibility .......................... yes
      FreeType ............................... yes
        Using system FreeType ................ no
      HarfBuzz ............................... yes
        Using system HarfBuzz ................ no
      Fontconfig ............................. no
      Image formats:
        GIF .................................. yes
        ICO .................................. yes
        JPEG ................................. yes
          Using system libjpeg ............... no
        PNG .................................. yes
          Using system libpng ................ no
      EGL .................................... no
      OpenVG ................................. no
      OpenGL:
        Desktop OpenGL ....................... no
        OpenGL ES 2.0 ........................ no
        OpenGL ES 3.0 ........................ no
        OpenGL ES 3.1 ........................ no
        OpenGL ES 3.2 ........................ no
      Vulkan ................................. yes
      Session Management ..................... yes
    Features used by QPA backends:
      evdev .................................. no
      libinput ............................... no
      INTEGRITY HID .......................... no
      mtdev .................................. no
      tslib .................................. no
      xkbcommon .............................. no
      X11 specific:
        XLib ................................. no
        XCB Xlib ............................. no
        EGL on X11 ........................... no
    QPA backends:
      DirectFB ............................... no
      EGLFS .................................. no
      LinuxFB ................................ no
      VNC .................................... yes
      Mir client ............................. no
    Qt Sql:
      SQL item models ........................ yes
    Qt Widgets:
      GTK+ ................................... no
      Styles ................................. Fusion Windows
    Qt PrintSupport:
      CUPS ................................... no
    Qt Sql Drivers:
      DB2 (IBM) .............................. no
      InterBase .............................. no
      MySql .................................. no
      OCI (Oracle) ........................... no
      ODBC ................................... no
      PostgreSQL ............................. no
      SQLite2 ................................ no
      SQLite ................................. yes
        Using system provided SQLite ......... no
      TDS (Sybase) ........................... no
    Qt Testlib:
      Tester for item models ................. yes
    
    Note: Also available for Linux: linux-clang linux-icc
    
    WARNING: No QPA platform plugin enabled! This will
    produce a Qt that cannot run GUI applications.
    See "Platform backends" in the output of --help.
    
    ERROR: Qt requires a compliant STL library.
    
    ERROR: C++11 <random> is required and is missing or failed to compile.
    
    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.
    
    

    As far as I understand, I may need to explicitly say where the STL is located. I am not sure how to do that. I also believe that the c++11 issue is common but I do not understand the fixes.

    Searching each individual error has not drawn me to any information that I have recognized as relevant. Forgive anything obvious I may have missed.

    Any help is very much appreciated!



  • @lui5468_ have you been following any guide for cross-compiling Qt for RPi? For example:

    1. Cross-compile and deploy Qt 5.12 for Raspberry Pi
    2. RaspberryPi2EGLFS

    At a glance it looks like you're missing providing what cross-compiler to use and that your sysroot folder is missing some required libraries (you need to install such libraries in your RPi device and then copy/rsync into your host PC)



  • @Pablo-J-Rogina Thank you so much for responding!

    I have not been following any guides here on the QT forums. I am following another guide, actually my third such guide. I guess it is time to move on to try another one. I am sure I will have better luck with a guide here on the forums. Thanks so much for taking a look and pointing me in the right direction!

    -Luis



  • @lui5468_ said in Errors when generating makefile for cross compile qt from host ubuntu and raspberry pi 4B:

    I am following another guide, actually my third such guide.

    Just in case, could it be possible you provide links to such guide(s)?



  • @Pablo-J-Rogina At the moment, I am cross referencing these two guides to get the configure to work:

    https://www.youtube.com/watch?v=TmtN3Rmx9Rk&t=1231s

    https://wapel.de/?p=842


Log in to reply