Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Build errors in cross compile Qt for embedded linux

Build errors in cross compile Qt for embedded linux

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
17 Posts 2 Posters 4.9k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    rahul3349
    wrote on 11 Jan 2016, 09:47 last edited by rahul3349 2 May 2016, 06:29
    #1

    I always get below mentioned errors in qtbase and qtwayland when I cross compile code for embedded linux
    Errors are mainly in below two categories,

    1. Related to header file include missing:
      ../../include/QtCore/../../src/corelib/io/qtextstream.h:46:2: error: #error qtextstream.h must be included before any header file that defines Status

    2. Related double defined types like Bool, KeyPress, KeyRelease, FontChange, CursorShape etc.
      /home/rbhagwat/sources/temp/linux/include/X11/Xlib.h:86:14: error: expected identifier before 'int'
      #define Bool int

    full error log of qtbase is here

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 12 Jan 2016, 00:08 last edited by
      #2

      Hi,

      Which version of Qt are you cross-compiling ?
      For what platform/board ?
      What options did you pass to configure ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • R Offline
        R Offline
        rahul3349
        wrote on 12 Jan 2016, 04:19 last edited by rahul3349 1 Dec 2016, 04:19
        #3

        I've same issue with multiple Qt versions like 5.4.2, dev, Qt 5.6.0.
        I'm building it for tegra platform

        ./configure -platform linux-g++ -xplatform linux-tegra-g++ -pkg-config -no-directfb -no-linuxfb -eglfs -system-xcb -cups -nis -no-pch -largefile -accessibility -opengl -glib -icu -dbus -evdev -no-rpath -release -verbose -opensource -confirm-license -sysroot "$SYSROOT_DIR" -extprefix "$QtInstallDir"

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 12 Jan 2016, 08:01 last edited by
          #4

          I may be wrong but -system-xcb looks suspicious for a cross-compiling configuration. Do you have all these libs available for your target ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • R Offline
            R Offline
            rahul3349
            wrote on 12 Jan 2016, 09:05 last edited by rahul3349 1 Dec 2016, 09:06
            #5

            Yes, I've all deps/libs in my sysroot, I'm able to cross compile Qt by resolving build errors. Problem is I need to create patches of fixing build issues and maintain it per Qt version.
            I'm expecting, Qt should be built w/o any build errors.

            1 Reply Last reply
            0
            • R Offline
              R Offline
              rahul3349
              wrote on 12 Jan 2016, 09:37 last edited by
              #6

              I've to create patch like this in order to fix build issues in qtbase

              1 Reply Last reply
              0
              • S Offline
                S Offline
                SGaist
                Lifetime Qt Champion
                wrote on 12 Jan 2016, 21:13 last edited by
                #7

                It should yes, that's why I'm thinking there something funky going one. Did you get the sources from git ?

                Interested in AI ? www.idiap.ch
                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • R Offline
                  R Offline
                  rahul3349
                  wrote on 13 Jan 2016, 04:07 last edited by
                  #8

                  Yes, I'm using source from git. Am I doing something wrong here?

                  1 Reply Last reply
                  0
                  • S Offline
                    S Offline
                    SGaist
                    Lifetime Qt Champion
                    wrote on 13 Jan 2016, 22:31 last edited by
                    #9

                    No no, it was just to know where you got the sources from.

                    What distribution do you have on your sysroot ?

                    Interested in AI ? www.idiap.ch
                    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    0
                    • R Offline
                      R Offline
                      rahul3349
                      wrote on 14 Jan 2016, 09:00 last edited by
                      #10

                      x11proto-kb-dev
                      x11proto-core-dev
                      x11proto-render-dev
                      libpcre3-dev
                      libxcb-render-util0-dev
                      libxau-dev
                      libxdmcp-dev
                      libpthread-stubs0-dev
                      libicu-dev
                      libxcb-util0-dev
                      libdbus-1-dev
                      libxcb-icccm4-dev
                      libxcb-image0-dev
                      libxcb-keysyms1-dev
                      libxext-dev
                      libxrender-dev
                      libx11-dev
                      libx11-xcb-dev
                      libexpat1-dev
                      libxcb-randr0-dev
                      libxcb-render0-dev
                      libxcb-shape0-dev
                      libxcb-shm0-dev
                      libxcb-xfixes0-dev
                      libfreetype6-dev
                      libglib2.0-dev
                      libfontconfig1-dev
                      libxcb1-dev
                      liborc-0.4-dev
                      libxrandr-dev
                      libxv-dev
                      libasound2-dev
                      libgstreamer1.0-dev
                      libgstreamer-plugins-base1.0-dev
                      libgstreamer-plugins-bad1.0-dev
                      libgstreamer-plugins-good1.0-dev
                      libxml2-dev
                      libjpeg8-dev
                      libjpeg-turbo8-dev
                      libc6-dev
                      libxkbcommon-dev
                      libffi-dev
                      libgettextpo-dev
                      gettext
                      libogg-dev
                      libvorbis0a
                      libvorbisenc2
                      libvorbis-dev
                      libvorbisfile3
                      libstdc++-4.8-dev
                      libxcb-xkb1
                      libxkbcommon-x11-dev
                      libevdev-dev
                      xserver-xorg-input-evdev-dev
                      libcups2-dev
                      nis
                      libxcb-sync-dev
                      libudev-dev
                      libcurl4-openssl-dev
                      openssl
                      libxcb-xkb-dev
                      libpulse-dev
                      libcap-dev
                      gperf
                      libgconf2-dev
                      libgcrypt11-dev
                      libgnome-keyring-dev
                      libnss3-dev
                      libpci-dev
                      libxtst-dev
                      python-gtk2-dev
                      libbz2-dev
                      libdrm-dev
                      libssl-dev
                      libxcursor-dev
                      libxcomposite-dev
                      libxdamage-dev
                      libxslt1-dev
                      libgeoclue-dev
                      libgypsy-dev
                      libjasper-dev
                      libmng-dev
                      libtiff5-dev
                      libwebp-dev
                      libxcb-xinerama0-dev

                      1 Reply Last reply
                      0
                      • S Offline
                        S Offline
                        SGaist
                        Lifetime Qt Champion
                        wrote on 14 Jan 2016, 11:13 last edited by
                        #11

                        But what Linux distribution are you using for your target sysroot ?

                        Interested in AI ? www.idiap.ch
                        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                        1 Reply Last reply
                        0
                        • R Offline
                          R Offline
                          rahul3349
                          wrote on 20 Jan 2016, 04:06 last edited by
                          #12

                          Ubuntu 15.04

                          1 Reply Last reply
                          0
                          • S Offline
                            S Offline
                            SGaist
                            Lifetime Qt Champion
                            wrote on 20 Jan 2016, 21:08 last edited by
                            #13

                            Ubuntu on the target and as sysroot ?

                            Interested in AI ? www.idiap.ch
                            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                            1 Reply Last reply
                            0
                            • R Offline
                              R Offline
                              rahul3349
                              wrote on 21 Jan 2016, 04:39 last edited by
                              #14

                              Ubuntu 15.04 is on target. I created sysroot by downloading arm 64 bit deb packages to resolve all Qt dependencies on host.

                              1 Reply Last reply
                              0
                              • S Offline
                                S Offline
                                SGaist
                                Lifetime Qt Champion
                                wrote on 21 Jan 2016, 21:16 last edited by
                                #15

                                One possibility is to add the QTextStream include where that error appears.

                                As for the X11 related errors, try moving the X11 includes after the Qt includes.

                                Interested in AI ? www.idiap.ch
                                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                1 Reply Last reply
                                0
                                • R Offline
                                  R Offline
                                  rahul3349
                                  wrote on 27 Jan 2016, 10:56 last edited by
                                  #16

                                  My intention behind starting this discussion is to avoid resolving build errors when I sync up or switch to new Qt version at my side. As I mentioned I've already resolved build errors and created patches for some Qt versions. But if those errors are fixed there itself as these are genuine build errors then developer do not have to resolve these errors for linux embedded platforms.

                                  1 Reply Last reply
                                  0
                                  • S Offline
                                    S Offline
                                    SGaist
                                    Lifetime Qt Champion
                                    wrote on 27 Jan 2016, 21:28 last edited by
                                    #17

                                    Did you submit your patches for inclusion in Qt ?

                                    Interested in AI ? www.idiap.ch
                                    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                    1 Reply Last reply
                                    0

                                    2/17

                                    12 Jan 2016, 00:08

                                    topic:navigator.unread, 15
                                    • Login

                                    • Login or register to search.
                                    2 out of 17
                                    • First post
                                      2/17
                                      Last post
                                    0
                                    • Categories
                                    • Recent
                                    • Tags
                                    • Popular
                                    • Users
                                    • Groups
                                    • Search
                                    • Get Qt Extensions
                                    • Unsolved