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. Cross-compilation on PC/UBUNTU for target PANDABOARD/UBUNTU.
Forum Updated to NodeBB v4.3 + New Features

Cross-compilation on PC/UBUNTU for target PANDABOARD/UBUNTU.

Scheduled Pinned Locked Moved Mobile and Embedded
18 Posts 2 Posters 8.6k 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.
  • R Offline
    R Offline
    reme
    wrote on last edited by
    #9

    Hi,

    Indeed there are problems during the new configure with -xcb.
    I read src/plugins/platforms/xcb/README and install all the dependency packages for libxcb.
    I found all the libraries thanks to the following command :
    sudo apt-cache pkgnames | grep "libxcb*"

    So, I do not understand why the last 3 lines of the message :
    "The test for linking against libxcb failed!
    You might need to install dependency packages for libxcb.
    See src/plugins/platforms/xcb/README"

    The result of the configure command is the following :
    Sorry for the size of the message but I am not able to specify which piece of information is important.

    ./configure -xcb -v -prefix /home/stimg/QT/qt-everywhere-opensource-src-5.2.1/qtbase -skip connectivity -qreal float -nomake tests -nomake examples -opensource -xplatform linux-arm-gnueabi-g++

    //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    BEGIN MESSAGE
    //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

    DEFAULT_LIBDIRS="/usr/lib/gcc/arm-linux-gnueabihf/4.6
    /usr/lib/gcc/arm-linux-gnueabihf/lib
    Creating qmake...
    make: Nothing to be done for `first'.
    Running configuration tests...
    Warning: Disabling pkg-config since PKG_CONFIG_LIBDIR is not set.
    Warning: Disabling pkg-config since PKG_CONFIG_SYSROOT_DIR is not set.
    Determining architecture... ()
    arm-linux-gnueabihf-g++-4.6 -c -pipe -g -Wall -W -fPIE -I../../mkspecs/linux-arm-gnueabi-g++ -I. -o arch.o arch.cpp
    arm-linux-gnueabihf-g++-4.6 -o arch arch.o
    /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi
    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 i386linux elf_l1om elf_k1om
    collect2: ld returned 1 exit status
    make: *** [arch] Error 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
    { test -n "" && DESTDIR="" || DESTDIR=.; } && test $(gdb --version | sed -e 's,[^0-9][^0-9]([0-9]).([0-9]).,\1\2,;q') -gt 72 && gdb --nx --batch --quiet -ex 'set confirm off' -ex "save gdb-index $DESTDIR" -ex quit 'arch' && test -f arch.gdb-index && objcopy --add-section '.gdb_index=arch.gdb-index' --set-section-flags '.gdb_index=readonly' 'arch' 'arch' && rm -f arch.gdb-index || true
    Found architecture in binary
    CFG_HOST_ARCH="x86_64"
    CFG_HOST_CPUFEATURES=" mmx sse sse2"
    System architecture: 'unknown'
    Host architecture: 'x86_64'
    C++11 auto-detection... ()
    arm-linux-gnueabihf-g++-4.6 -c -pipe -O2 -std=c++0x -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o c++11.o c++11.cpp
    arm-linux-gnueabihf-g++-4.6 -Wl,-O1 -o c++11 c++11.o
    /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi
    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 i386linux elf_l1om elf_k1om
    collect2: ld returned 1 exit status
    make: *** [c++11] Error 1
    C++11 disabled.
    floatmath auto-detection... ()
    arm-linux-gnueabihf-g++-4.6 -c -pipe -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o floatmath.o floatmath.cpp
    floatmath.cpp:44:5: warning: unused parameter ‘argc’ [-Wunused-parameter]
    floatmath.cpp:44:5: warning: unused parameter ‘argv’ [-Wunused-parameter]
    arm-linux-gnueabihf-g++-4.6 -Wl,-O1 -o floatmath floatmath.o
    /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi

    ...

    evdev disabled.
    XLib auto-detection... ()
    arm-linux-gnueabihf-g++-4.6 -c -pipe -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o xlib.o xlib.cpp
    arm-linux-gnueabihf-g++-4.6 -Wl,-O1 -o xlib xlib.o -lXext -lX11 -lm
    /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi
    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 i386linux elf_l1om elf_k1om
    collect2: ld returned 1 exit status
    make: *** [xlib] Error 1
    XLib disabled.
    xcb auto-detection... ()
    arm-linux-gnueabihf-g++-4.6 -c -pipe -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o xcb.o xcb.cpp
    xcb.cpp: In function ‘int main(int, char**)’:
    xcb.cpp:47:23: warning: unused variable ‘t’ [-Wunused-variable]
    arm-linux-gnueabihf-g++-4.6 -Wl,-O1 -o xcb xcb.o -lxcb
    /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi
    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 i386linux elf_l1om elf_k1om
    collect2: ld returned 1 exit status
    make: *** [xcb] Error 1
    xcb disabled.
    The test for linking against libxcb failed!
    You might need to install dependency packages for libxcb.
    See src/plugins/platforms/xcb/README.
    /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    END MESSAGE
    /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #10

      You need the arm version of these libraries

      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
        reme
        wrote on last edited by
        #11

        Hi

        I put all the xcb libraries loaded on my PANDABOARD/UBUNTU described in the README in the directory :
        /usr/lib/gcc/arm-linux-gnueabihf/4.6 on my PC/UBUNTU.
        But the result is always the same after the configuration :

        xcb disabled.
        The test for linking against libxcb failed! You might need to install dependency packages for libxcb. See src/plugins/platforms/xcb/README.

        Best regards.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #12

          You should rather point the configure script to the folder where the libraries can be found they have dependencies that might not be seen

          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
            reme
            wrote on last edited by
            #13

            Hi

            I modified the file /usr/lib/gcc/arm-linux-gnueabihf/4.6/pkgconfig/xcb.pc
            thus I can specify the access to the static library libxcb.a (coming from my target). Nevertheless I obtain the same message :
            arm-linux-gnueabihf-g++-4.6 -Wl,-O1 -o xcb xcb.o -L//usr/lib/gcc/arm-linux-gnueabihf/4.6 -lxcb

            /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi
            Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 i386linux elf_l1om elf_k1om
            collect2: ld returned 1 exit status
            make: *** [xcb] Error 1
            xcb disabled.
            How must I resolve the problem /usr/bin/arm-linux-gnueabihf-ld: unrecognised emulation mode: armelf_linux_eabi ?

            Best regards.

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #14

              Looking for that error, it seems you might be encountering a bug of gcc

              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
                reme
                wrote on last edited by
                #15

                Hi

                It seems there is not any solution to my problem.

                Best regards.

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #16

                  The only I see is to update gcc, is there not a more recent version available ?

                  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
                    reme
                    wrote on last edited by
                    #17

                    I do not find a more recent version but I find a workaround.
                    I am not sure to well understant it.
                    The workaround suggests to modify the configure.tgt file for the linker :

                    This is the linker target specific file. This is invoked by the autoconf generated configure script. Putting it in a separate shell file lets us skip running autoconf when modifying target specific.

                    The content of the config.tgt is the following :
                    --- ld/configure.tgt.orig 2011-04-05 20:22:23.000000000 +0000

                                        targ_extra_emuls="armelfb armelf armelf_linux" 
                                        targ_extra_libpath="armelf_linux" 
                                        ;; 
                    

                    -arm*--linux-eabi) targ_emul=armelf_linux_eabi
                    +arm
                    -
                    -linux-eabi) targ_emul=armelf_linux_eabi
                    targ_extra_emuls=armelfb_linux_eabi
                    targ_extra_libpath=$targ_extra_emuls

                                        targ_extra_emuls="armelf armelfb armelfb_linux" 
                                        targ_extra_libpath="armelfb_linux" 
                                        ;; 
                    

                    -arm*--uclinuxeabi) targ_emul=armelf_linux_eabi
                    +arm*--uclinuxeabi*) targ_emul=armelf_linux_eabi
                    targ_extra_emuls=armelfb_linux_eabi
                    targ_extra_libpath=$targ_extra_emuls
                    ;;

                    For me I need to compile the loader arm-linux-gnueabi-g++-4.6 by using the previous file.

                    Do you agree ?

                    Thanks and best regards.

                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on last edited by
                      #18

                      Worth to try

                      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

                      • Login

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