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. How to arm cross-compile in windows for Linux ?
QtWS25 Last Chance

How to arm cross-compile in windows for Linux ?

Scheduled Pinned Locked Moved Installation and Deployment
10 Posts 3 Posters 4.0k 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
    ranshalit
    wrote on last edited by
    #1

    Hello,

    I try to cross-compile for arm a QT 4.8.1 application in windows machine for linux machine.
    I have found the following link:
    "http://visualgdb.com/tools/QtCrossTool/":http://visualgdb.com/tools/QtCrossTool/
    Which described how this can be done.
    I would like to ask:

    What is the meaning of the remote machine ? I don't have a remote machine on this computer from where I compile ? Is it required ?
    Is the above method from the link is recommended or there is a better way ?

    Thank you,
    Ran

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

      "remote machine" refers to the board, in this case the Raspberry Pi.

      1 Reply Last reply
      0
      • R Offline
        R Offline
        ranshalit
        wrote on last edited by
        #3

        Hi,

        On trying to select the "remote machine" it opens ssh connection. Why should I connect to remote machine ? Is the above method the best way to do cross compile for arm ?

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

          Hi,

          Because you are building an application to run on said remote machine, in this example the Raspberry PI so the remote machine is needed to run/debug your application and also needed to deploy the Qt libraries on to be able to run/debug your application. All ARM devices don't run the same OS and in the case of Linux not all are running the same distribution so you can't just have a one binary fits all.

          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
            ranshalit
            wrote on last edited by
            #5

            Hi,

            Thanks for the reply. I probably did not clear what I try to do....
            I already installed target with lib for qt 4.8.1 and I have the ability to cross- compile application for arm running in Linux. The thing now, is that I am in dillema: I need to provide windows's user thecapability to compile the QT for arm (running on Linux), so I have 2 options:

            1. provide virtual machine with this arm cross-compilation capability as I already have in my laptop.
              2, use some method for cross compile to arm on Windows machine.
              I thought that option 2 will be better (because I deal with windows software group, and they rather not use Linux), but it turns out to be complex task. I still don't understand how this should be done. I found no information about it.

            Are you familiar with and wiki/blog which explains clearly how I can achieve option 2 or Do you think I better stick with option 1 ?
            Are all cross compilers for arm valid for this purpose (raspberry PI / beaglebone /codesourcery etc)
            Regards,
            Ran

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

              I'd go with the Linux virtual machine: way simpler to setup that environment

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

                Hello,

                When compiling the project in windows can we use any Qt sdk & qt creator or should it be the same qt sdk installed (4.8.1 in my case) ?
                As I said the method of development is:

                1. using windows for testing
                2. compiling in linux machine for the target

                Thanks,
                Ran

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

                  Well, in the absolute you should be using the same Qt version as your target to ensure that you have the same set of feature/patches/bugfixes. Qt Creator can be the latest version, it can handle several version of Qt without any problem.

                  You should rather do everything in your linux virtual machine, you'll gain time

                  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
                    ranshalit
                    wrote on last edited by
                    #9

                    Hi,

                    Thanks very much,
                    I would like to ask one more question, if I may.

                    The general idea in our developments with QT is :

                    1. use windows for all compile/debug/testing of the QT project.
                    2. copy the project to linux, and cross-compile it for the ARM target under Linux.
                    3. running the application in the ARM target.

                    What do you mean by "gain time" if we will do everything in Linux ? Do you find any problem in the method above ?

                    Thanks,
                    Ran

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

                      If you use linux for both the development and deployment on your arm device then you can use tools to debug/analyze your code as well as your device that should be on par with what your desktop proposes. In short: same debugger, same set of libraries, same environment and/or technologies

                      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