Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Failed to compile QT 4.7 to arm
QtWS25 Last Chance

Failed to compile QT 4.7 to arm

Scheduled Pinned Locked Moved Installation and Deployment
10 Posts 4 Posters 13.2k 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.
  • K Offline
    K Offline
    kani
    wrote on last edited by
    #1

    Hi
    I would like to compile QT 4.7 to arm tegra board.
    I have download QT 4.7 and run this command
    ./configure –platform qws/linux-arm-gnueabi-g++
    And I get this error
    g++: arm-linux-gnueabi-g++: No Such file or directory.
    I update the path with the relevant directory the crosscompile located.
    If I write this command this command in the shell
    arm-linux-gnueabi-g++
    the output is : no input files
    so it's seems the path is correct
    How can I solve this problem
    Kani

    1 Reply Last reply
    0
    • A Offline
      A Offline
      anselmolsm
      wrote on last edited by
      #2

      Hi kani,

      Try the following:

      @
      ./configure -platform linux-g++ -xplatform qws/linux-arm-gnueabi-g++
      @

      If you are not on Linux, adjust the platform parameter accordingly =)

      Anselmo L. S. Melo (anselmolsm)

      1 Reply Last reply
      0
      • K Offline
        K Offline
        kani
        wrote on last edited by
        #3

        Hi
        Yes i am on Linux machine (Ubuntu) ,
        The line didn't work it compiled it to X86.
        Any other ideas

        1 Reply Last reply
        0
        • A Offline
          A Offline
          anselmolsm
          wrote on last edited by
          #4

          This is the configure line used to build Qt for ARM here, the only difference is that here I build Qt for symbian/linux-gcce.

          The binaries (e.g. qmake, moc) will be compiled to x86 so you can run them in your system, but they will generate binaries for ARM.

          EDIT: Qt libs itself will be built for ARM.

          Anselmo L. S. Melo (anselmolsm)

          1 Reply Last reply
          0
          • L Offline
            L Offline
            luca
            wrote on last edited by
            #5

            I did this to compile for BeagleBoard (arm):

            • install beagleboard's tool-chain in /usr/local/angstrom (you must install your where you want)

            • extract qt 4.7 source

            • in the source edit mkspecs/qws/linux-arm-g++/qmake.conf remove the content and put:

            @

            QMAKE_CFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp
            QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE

            include(../../common/g++.conf)
            include(../../common/linux.conf)
            include(../../common/qws.conf)

            modifications to g++.conf

            QMAKE_CC = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-gcc
            QMAKE_CXX = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-g++
            QMAKE_LINK = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-g++
            QMAKE_LINK_SHLIB = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-g++

            modifications to linux.conf

            QMAKE_AR = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-ar cqs
            QMAKE_OBJCOPY = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-objcopy
            QMAKE_STRIP = /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-strip

            load(qt_config)
            @

            You must replace /usr/local/angstrom/arm/bin with your toolchain path and use the right binary (for example your cross-tool gcc should be arm-linux-gnueabi-g++ or arm-linux-g++ ecc... )

            • ./configure -opensource -confirm-license -no-qt3support -release -nomake examples -nomake demos -embedded arm -little-endian -xplatform qws/linux-arm-g++ -prefix /opt/qt4-4.7.0-beagle -qt-gfx-vnc

            • make

            • make install (as root)

            1 Reply Last reply
            0
            • K Offline
              K Offline
              kani
              wrote on last edited by
              #6

              hi
              thanks for all the reply i will try this
              and will post the result
              kani

              1 Reply Last reply
              0
              • K Offline
                K Offline
                kani
                wrote on last edited by
                #7

                Hi
                Thanks for the replays
                IN qt 4.7 I didn't find any xplatform or -embedded parameters in configuration help.
                I have tried ./configure -platform linux-g++ -xplatform qws/linux-arm-gnueabi-g++
                but all the bin and lib where compiled to x86 and not arm.
                Any others ideas? how to compile it to ARM env nvida tegra board
                Kani

                1 Reply Last reply
                0
                • A Offline
                  A Offline
                  anselmolsm
                  wrote on last edited by
                  #8

                  [quote author="kani" date="1285783223"]Hi
                  Thanks for the replays
                  IN qt 4.7 I didn't find any xplatform or -embedded parameters in configuration help.
                  [/quote]

                  Qt 4.7 has this parameter. Maybe it is not listed in --help, but it's another topic.

                  [quote author="kani" date="1285783223"]
                  I have tried ./configure -platform linux-g++ -xplatform qws/linux-arm-gnueabi-g++
                  but all the bin and lib where compiled to x86 and not arm.
                  Any others ideas? how to compile it to ARM env nvida tegra board
                  Kani
                  [/quote]

                  Check if your linux-arm-gnueabi-g++ is in your PATH. Also, take a look if there are other variables to adjust; you can find it in mkspec/qws/linux-arm-gnueabi-g++/qmake.conf

                  Anselmo L. S. Melo (anselmolsm)

                  1 Reply Last reply
                  0
                  • K Offline
                    K Offline
                    kani
                    wrote on last edited by
                    #9

                    I was able to compile a test app for arm in the same shell. so linux-arm-gnueabi-g++ is the path, but for some reason i get the error
                    arm-linux-gnueabi-g++ the output is : no input files

                    1 Reply Last reply
                    0
                    • M Offline
                      M Offline
                      marcio
                      wrote on last edited by
                      #10

                      I am trying to cross compile QT 4.7 for mini2440 without success. Below is the error:
                      make[1]: Entering directory /opt/qtsdk-2010.05/qt/src/corelib' /media/b1cc59e2-c2f4-4a5e-acee-fc4dada4edbe/opt/Boardcon/4.3.3/bin/arm-linux-g++ -c -include .pch/release-shared-emb-arm/QtCore -pipe -fno-exceptions -O0 -fvisibility=hidden -fvisibility-inlines-hidden -Wall -W -D_REENTRANT -fPIC -DQT_SHARED -DQT_BUILD_CORE_LIB -DQT_NO_USING_NAMESPACE -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT3_SUPPORT -DQT_MOC_COMPAT -DQT_USE_FAST_OPERATOR_PLUS -DQT_USE_FAST_CONCATENATION -DELF_INTERPRETER=\"/lib/ld-linux.so.2\" -DHB_EXPORT=Q_CORE_EXPORT -DQT_NO_DEBUG -I../../mkspecs/qws/linux-arm-g++ -I. -I../../include -I../../include/QtCore -I.rcc/release-shared-emb-arm -Iglobal -I../3rdparty/zlib -I../3rdparty/harfbuzz/src -I../3rdparty/md5 -I../3rdparty/md4 -I.moc/release-shared-emb-arm -I../../include -o .obj/release-shared-emb-arm/qvariantanimation.o animation/qvariantanimation.cpp In file included from animation/qvariantanimation.cpp:694: ../../include/QtCore/qatomic_i386.h: In member function 'bool QBasicAtomicInt::testAndSetOrdered(int, int)': ../../include/QtCore/qatomic_i386.h:144: error: impossible constraint in 'asm' {standard input}: Assembler messages: {standard input}:350: Error: bad instruction lock'
                      {standard input}:351: Error: bad instruction incl [r2,#0]' {standard input}:352: Error: bad instruction setne [fp,#-5]'
                      {standard input}:390: Error: bad instruction lock' {standard input}:391: Error: bad instruction decl [r2,#0]'
                      {standard input}:392: Error: bad instruction setne [fp,#-5]' make[1]: *** [.obj/release-shared-emb-arm/qvariantanimation.o] Error 1 make[1]: Leaving directory /opt/qtsdk-2010.05/qt/src/corelib'
                      make: *** [sub-corelib-make_default-ordered] Error 2

                      can anybody help me ?

                      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