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. Running Qt5 app on embedded platform
QtWS25 Last Chance

Running Qt5 app on embedded platform

Scheduled Pinned Locked Moved Mobile and Embedded
12 Posts 4 Posters 3.6k 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.
  • W Offline
    W Offline
    Without
    wrote on last edited by A Former User
    #1

    Hi All,

    For some years I run my QT5 applications on embedded platforms such as the beaglebone. I am only able to run these applications when I install qt5-default on the embedded platform. Without qt5-default the application will not run.

    I have created a little server test program that needs to run on a router that runs debian jessie (EdgeOS) on ARM v7. But I am unable to install qt5-default on this device.

    How can I run my program without installing qt5-default?

    Best regards,
    Without.

    1 Reply Last reply
    0
    • D Offline
      D Offline
      debian
      wrote on last edited by debian
      #2

      What is qt5-default?
      I think you can simple copy qt libraries and all should work.

      1 Reply Last reply
      0
      • W Offline
        W Offline
        Without
        wrote on last edited by
        #3

        qt5-default is a development package which contains all the dependencies to run a QT application.

        mrjjM 1 Reply Last reply
        0
        • W Without

          qt5-default is a development package which contains all the dependencies to run a QT application.

          mrjjM Offline
          mrjjM Offline
          mrjj
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @Without

          Unless you static link you app, it's not possible to run without the Qt so/dll files.
          ( static building require a Qt license or that the app is open source)

          So you must build a deployment folder containing these
          http://www.tripleboot.org/?p=138
          Scroll down to linux part.

          also see
          http://doc.qt.io/qt-5/deployment.html

          W 1 Reply Last reply
          0
          • mrjjM mrjj

            @Without

            Unless you static link you app, it's not possible to run without the Qt so/dll files.
            ( static building require a Qt license or that the app is open source)

            So you must build a deployment folder containing these
            http://www.tripleboot.org/?p=138
            Scroll down to linux part.

            also see
            http://doc.qt.io/qt-5/deployment.html

            W Offline
            W Offline
            Without
            wrote on last edited by
            #5

            @mrjj

            Thank you. That is exactly what I need. For future purposes I will build the QT5 sources for static linking but this will do for now.

            It is not a commercial project. We will use it for a in-house HTTP server.

            Best regards,
            Without.

            1 Reply Last reply
            1
            • W Offline
              W Offline
              Without
              wrote on last edited by
              #6

              I just build QT5.7 from source for static linking against the QT libs.

              This is the config I use fot static building: ./configure -static -opensource -release -developer-build -prefix /opt/Qt-5.7 -nomake examples -nomake tests

              I thought that the executable would run on a fresh install of Ubuntu without the need of installing external libs but I was wrong.

              Instead there is a huge list of dependencies. Do I have to install these by hand or are these libs part of a package?

              objdump -p TestServer | grep NEEDED
              NEEDED libxcb-glx.so.0
              NEEDED libXi.so.6
              NEEDED libxcb-render-util.so.0
              NEEDED libSM.so.6
              NEEDED libICE.so.6
              NEEDED libxcb-render.so.0
              NEEDED libxcb-image.so.0
              NEEDED libxcb-icccm.so.4
              NEEDED libxcb-sync.so.1
              NEEDED libxcb-xfixes.so.0
              NEEDED libxcb-shm.so.0
              NEEDED libxcb-randr.so.0
              NEEDED libxcb-shape.so.0
              NEEDED libxcb-keysyms.so.1
              NEEDED libxcb-xinerama.so.0
              NEEDED libxcb-xkb.so.1
              NEEDED libxkbcommon-x11.so.0
              NEEDED libxkbcommon.so.0
              NEEDED libjasper.so.1
              NEEDED libtiff.so.5
              NEEDED libwebp.so.5
              NEEDED libwebpdemux.so.1
              NEEDED libgbm.so.1
              NEEDED libdrm.so.2
              NEEDED libX11-xcb.so.1
              NEEDED libxcb.so.1
              NEEDED libX11.so.6
              NEEDED libudev.so.1
              NEEDED libfontconfig.so.1
              NEEDED libfreetype.so.6
              NEEDED libjpeg.so.8
              NEEDED libpng12.so.0
              NEEDED libEGL.so.1
              NEEDED libdbus-1.so.3
              NEEDED libmysqlclient.so.18
              NEEDED libodbc.so.1
              NEEDED libpq.so.5
              NEEDED libsybdb.so.5
              NEEDED libz.so.1
              NEEDED libicui18n.so.52
              NEEDED libicuuc.so.52
              NEEDED libdl.so.2
              NEEDED libglib-2.0.so.0
              NEEDED librt.so.1
              NEEDED libGL.so.1
              NEEDED libpthread.so.0
              NEEDED libstdc++.so.6
              NEEDED libm.so.6
              NEEDED libgcc_s.so.1
              NEEDED libc.so.6
              NEEDED ld-linux.so.2

              Best regards,
              Without.

              1 Reply Last reply
              0
              • mrjjM Offline
                mrjjM Offline
                mrjj
                Lifetime Qt Champion
                wrote on last edited by mrjj
                #7

                Hmm, i expected it to just run also.
                That is what happened in Windows.
                You are 100% sure, you used the static version of qt when compiling?
                I guess yes since no Qt seems listed.
                Also, this is a completely normal Ubuntu you run on ?
                ( not a reduced or special)

                I never tried static in linux so Let's see if we get get some input from others :)

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

                  Hi,

                  Qt might be build statically that doesn't mean that each of its dependencies are done the same way.

                  From what I see, here are the dependencies of the xcb, sql and image plugins.

                  If you want a full static application you also have to build against all dependencies built statically.

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

                  W 1 Reply Last reply
                  2
                  • SGaistS SGaist

                    Hi,

                    Qt might be build statically that doesn't mean that each of its dependencies are done the same way.

                    From what I see, here are the dependencies of the xcb, sql and image plugins.

                    If you want a full static application you also have to build against all dependencies built statically.

                    W Offline
                    W Offline
                    Without
                    wrote on last edited by
                    #9

                    @SGaist

                    Ok thank you. I will investigate further.

                    Hooray for Microsoft. In visual studio you only have to set the build to static and in release mode and the exe runs on virgin Windows installs. If you want to do the same with QT you are screwed and have to build QT yourself and spend many hours / days trying to figure out why it is not working. Why bother the programmer with such crap.

                    1 Reply Last reply
                    0
                    • mrjjM mrjj

                      Hmm, i expected it to just run also.
                      That is what happened in Windows.
                      You are 100% sure, you used the static version of qt when compiling?
                      I guess yes since no Qt seems listed.
                      Also, this is a completely normal Ubuntu you run on ?
                      ( not a reduced or special)

                      I never tried static in linux so Let's see if we get get some input from others :)

                      W Offline
                      W Offline
                      Without
                      wrote on last edited by
                      #10

                      @mrjj

                      Yes it is a complete Ubuntu install. If I install qt5-default the program runs fine but with static compiling of QT I thought that I did not need qt5-default anymore. But I was wrong..

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

                        No it won't unless you specify that you also want the static runtime to be used which means that you have to follow updates to the runtime because your application won't benefit from new versions of it.

                        Most libraries don't use the static runtime. In the end it's the programmers responsibility to choose one or the other mode.

                        If you don't want that, then use MinGW in place of VS.

                        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
                        • W Offline
                          W Offline
                          Without
                          wrote on last edited by
                          #12

                          I switched to MS MFC instead. Visual studio compiles a static exe when I set the build to static / release and runs fine on Win7, Win8, Win10. I like QT but it bothers me with complicated configuration which is not very well documented and differs from time to time due to different QT and OS versions. And my personal opinion is that you don`t have to bother the application programmer with that.

                          Thank you mrjj for your support!

                          Best regards,
                          Without.

                          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