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. Problem to build Qt5 for Udoo quad
Forum Updated to NodeBB v4.3 + New Features

Problem to build Qt5 for Udoo quad

Scheduled Pinned Locked Moved Mobile and Embedded
9 Posts 3 Posters 4.0k Views 1 Watching
  • 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.
  • M Offline
    M Offline
    modjo
    wrote on 8 Oct 2014, 21:25 last edited by
    #1

    Hi all, i'm trying to buid Qt5 for my udoo quad but i have somes problems. first, i'm trying to cross compile with this tutorial : "buid Qt5 Udoo":http://www.udoo.org/ProjectsAndTutorials/how-to-build-qt5-for-udoo/?portfolioID=1394 . I use the Udoobuntu fileSystem : "OS":http://www.udoo.org/downloads/

    After my qmake.conf :

    @
    include(../common/linux_device_pre.conf)

    ROOTFS_PATH=/home/modjo/Udoo/Qt5_build
    TOOLCHAIN_PREFIX=/home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin

    EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfshooks_imx6.cpp

    QMAKE_INCDIR += $${ROOTFS_PATH}/usr/include $${ROOTFS_PATH}/usr/bin
    QMAKE_LIBDIR += $${ROOTFS_PATH}/usr/lib/arm-linux-gnueabihf $${ROOTFS_PATH}/usr/lib

    QMAKE_INCDIR_OPENGL_ES2 += /home/modjo/Udoo/Qt5_build/usr/include/GLES2
    QMAKE_LIBDIR_OPENGL_ES2 += /home/modjo/Udoo/Qt5_build/usr/lib/GLESv2
    #QMAKE_LIBS_EGL += /home/modjo/Udoo/Qt5_build/usr/lib/GLESv2
    #QMAKE_LIBS_OPENGL_ES2 += /home/modjo/Udoo/Qt5_build/usr/lib/GLESv2
    #QMAKE_LIBS_OPENVG += /home/modjo/Udoo/Qt5_build/usr/lib/OpenVG
    QMAKE_LIBS_EGL += -lEGL
    QMAKE_LIBS_OPENGL_ES2 += -lGLESv2 -lEGL -lGAL
    QMAKE_LIBS_OPENVG += -lOpenVG -lEGL -lGAL
    QMAKE_LFLAGS += -Wl,-rpath-link,$$/home/modjo/Udoo/Qt5_build/lib/arm-linux-gnueabihf
    IMX6_CFLAGS = -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1
    QMAKE_CFLAGS += $$IMX6_CFLAGS
    QMAKE_CXXFLAGS += $$IMX6_CFLAGS
    include(../common/linux_arm_device_post.conf)
    load(qt_config)
    @

    when i use configure :

    @
    ./configure -prefix /opt/qt5 -make libs -no-pch -no-opengl -device imx6 -device-option CROSS_COMPILE=/home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/ -no-largefile -opengl es2 -qt-zlib -qt-libpng -qt-libjpeg -no-nis -no-cups -gui -make examples -sysroot /home/modjo/Udoo/Qt5_build/exemples -no-gcc-sysroot -opensource -confirm-license -qreal float -v
    @

    i have this errors :
    @
    /home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/g++ -c -pipe -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1 -mfloat-abi=softfp -g -Wall -W -fPIE -I../../mkspecs/devices/linux-imx6-g++ -I. -I../../../../usr/include -I../../../../usr/bin -o arch.o arch.cpp
    g++: error trying to exec 'cc1plus': execvp: No such file or directory
    Messages de l'assembleur:
    Erreur fatale: option -march= invalide: « armv7-a »
    gmake: *** [arch.o] Erreur 1
    Unable to determine architecture!

    Could not determine the target architecture!
    Turn on verbose messaging (-v) to see the final report.
    Determining architecture... ()
    g++ -c -pipe -g -Wall -W -fPIE -I../../mkspecs/linux-g++ -I. -o arch.o arch.cpp
    g++ -o arch arch.o
    Found architecture in binary
    CFG_HOST_ARCH="i386"
    CFG_HOST_CPUFEATURES=""
    System architecture: 'unknown'
    Host architecture: 'i386'
    C++11 auto-detection... ()
    /home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/g++ -c -pipe -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1 -mfloat-abi=softfp -O2 -std=c++0x -Wall -W -fPIE -I../../../mkspecs/devices/linux-imx6-g++ -I. -I/home/modjo/Udoo/Qt5_build/usr/include -I/home/modjo/Udoo/Qt5_build/usr/bin -o c++11.o c++11.cpp
    g++: error trying to exec 'cc1plus': execvp: No such file or directory
    Messages de l'assembleur:
    Erreur fatale: option -march= invalide: « armv7-a »
    gmake: *** [c++11.o] Erreur 1
    C++11 disabled.
    floatmath auto-detection... ()
    /home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/g++ -c -pipe -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1 -mfloat-abi=softfp -O2 -Wall -W -fPIE -I../../../mkspecs/devices/linux-imx6-g++ -I. -I/home/modjo/Udoo/Qt5_build/usr/include -I/home/modjo/Udoo/Qt5_build/usr/bin -o floatmath.o floatmath.cpp
    g++: error trying to exec 'cc1plus': execvp: No such file or directory
    Messages de l'assembleur:
    Erreur fatale: option -march= invalide: « armv7-a »
    gmake: *** [floatmath.o] Erreur 1
    floatmath disabled.
    .....
    OpenGL ES 2.x auto-detection... ()
    /home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/g++ -c -pipe -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1 -mfloat-abi=softfp -O2 -Wall -W -fPIE -I../../../mkspecs/devices/linux-imx6-g++ -I. -I/home/modjo/Udoo/Qt5_build/usr/include/GLES2 -I/home/modjo/Udoo/Qt5_build/usr/include -I/home/modjo/Udoo/Qt5_build/usr/bin -o opengles2.o opengles2.cpp
    g++: error trying to exec 'cc1plus': execvp: No such file or directory
    Messages de l'assembleur:
    Erreur fatale: option -march= invalide: « armv7-a »
    gmake: *** [opengles2.o] Erreur 1
    OpenGL ES 2.x disabled.
    The OpenGL ES 2.0 functionality test 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
    /home/modjo/Udoo/Qt5_build/qt5/qtbase/mkspecs/devices/linux-imx6-g++.
    @

    I search on this forum (and udoo, freescale ...) but i found nothing who can help me. Do you have an idea to resolve this ?

    For information, i also tried to build directly qt on the udoo board, but i obtain this error

    @
    ubuntu@udoobuntu: ~/Qt5.3/qt-everywhere-opensource-src-5.3.2 $ sudo ./configure -prefix /opt/qt5 -make libs -no-pch -no-opengl -no-largefile -opengl es2 -qt-zlib -qt-libpng -qt-libjpeg -no-nis -no-cups -gui -make examples -sysroot ~/Qt5.3/examples -no-gcc-sysroot -opensource -confirm-license -qreal float -v
    ....
    collect2: ld returned 1 exit status
    make: *** [opengles2] Error 1
    OpenGL ES 2.x disabled.
    The OpenGL ES 2.0 functionality test 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
    /home/ubuntu/Qt5.3/qt-everywhere-opensource-src-5.3.2/qtbase/mkspecs/linux-g++.
    @

    I dowloaded the source code here (not git) : "qt5.3":http://download.qt-project.org/official_releases/qt/5.3/5.3.2/single/qt-everywhere-opensource-src-5.3.2.tar.gz

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 9 Oct 2014, 22:39 last edited by
      #2

      Hi and welcome to devnet,

      The key work here is:

      @Erreur fatale: option -march= invalide: « armv7-a »@

      Seems armv7-a is problematic.

      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
      • M Offline
        M Offline
        modjo
        wrote on 10 Oct 2014, 20:52 last edited by
        #3

        Ok, thanks for your answer ! Do you have an idea about this problem ? the compiler don't recognize the plateform ?

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 11 Oct 2014, 22:43 last edited by
          #4

          Looks like your version of gcc doesn't support it. Are you sure you are using a recent enough version ?

          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
          • M Offline
            M Offline
            modjo
            wrote on 13 Oct 2014, 20:20 last edited by
            #5

            ok, i make this :

            @
            ubuntu@udoobuntu: ~ $ gcc -v
            Using built-in specs.
            COLLECT_GCC=gcc
            COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabihf/4.6/lto-wrapper
            Target: arm-linux-gnueabihf
            Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 4.6.3-1ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --enable-plugin --enable-objc-gc --enable-multilib --disable-sjlj-exceptions --with-arch=armv7-a --with-float=hard --with-fpu=vfpv3-d16 --with-mode=thumb --disable-werror --enable-checking=release --build=arm-linux-gnueabihf --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf
            Thread model: posix
            gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5)

            @

            It's the official version give by Udoo : "Toolchain":https://github.com/embest-tech/fsl-linaro-toolchain.git
            if i need to use a newer version, i suppose that i need to build a new kernel ?

            1 Reply Last reply
            0
            • S Offline
              S Offline
              SGaist
              Lifetime Qt Champion
              wrote on 13 Oct 2014, 21:24 last edited by
              #6

              I've been a bit misled by the errors you got. You have the right compiler, it's something else that make things fail.

              Anyway, there's something that seems not quiet clear. Where do you have Qt's sources located ? Same question for the sysroot and toolchain

              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
              • A Offline
                A Offline
                ariacorrente
                wrote on 14 Oct 2014, 12:57 last edited by
                #7

                Hi,

                I'm not an expert but i'm working on the same board trying to compile Qt5 on the same OS and failed. I wrote as user "nicola" a "thread on the Udoo forums":http://www.udoo.org/forum/cross-compile-qt5-udoobuntu-t1540.html , maybe there is something of use there.

                [quote author="modjo" date="1413231642"]ok, i make this :

                @
                ubuntu@udoobuntu: ~ $ gcc -v
                @

                [/quote]
                From your console prompt i understand you executed this command in the target machine (the Udoo board).
                The error messages quoted in the above messages are instead generated by the cross-compiler pointed by the "COSS_COMPILE" configure option. I think SGaist asked about the cross-compiler version.

                About the cross compiler you used:
                @-device-option CROSS_COMPILE=/home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/@
                Now i see something strange in the value used as CROSS_COMPILER option. I think you need to use the prefix path of the compiler, not a folder. For example in the tutorial on the Udoo site they use this:
                @-device-option CROSS_COMPILE=/path/to/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi-@
                Then "make" will append for example "gcc" or "ar" to complete the path according to the operation required.
                In you error message "./configure" tried to execute
                @/home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin/g++ <lots of parameters>
                g++: error trying to exec 'cc1plus': execvp: No such file or directory@
                but there is no "g++" executable in the "home/modjo/Udoo/Qt5_build/fsl-linaro-toolchain/arm-fsl-linux-gnueabi/bin" folder of the cross compiler. At least not in the version recomended by the udoo tutorial i used.

                I hope I haven't written too many mistakes.

                1 Reply Last reply
                0
                • S Offline
                  S Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on 14 Oct 2014, 21:01 last edited by
                  #8

                  I've missed the g++ vs arm-fsl-linux-gnueabi-g++ !

                  That's one of the key point here, thanks !

                  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
                  • M Offline
                    M Offline
                    modjo
                    wrote on 15 Oct 2014, 19:51 last edited by
                    #9

                    Hi ariacorrente, happy to read you on this forum ! Thanks for your help (SGaist also !). For the moment i'm just trying to cross compile QT5 on linaro ubuntu (not udoobuntu) like the tutorial explain. If i will have a success i will try another time on udoobuntu !

                    1 Reply Last reply
                    0

                    1/9

                    8 Oct 2014, 21:25

                    • Login

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