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 deploy a Windows application on a Windows 10 clean PC?
Forum Updated to NodeBB v4.3 + New Features

How to deploy a Windows application on a Windows 10 clean PC?

Scheduled Pinned Locked Moved Solved Installation and Deployment
14 Posts 3 Posters 3.5k Views 3 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.
  • L Offline
    L Offline
    lqsa
    wrote on 11 Oct 2017, 14:45 last edited by lqsa 10 Nov 2017, 15:06
    #1

    I've created an application with Qt 5.9.2. On my development laptop, the application works well, but when I try to run it on a clean Windows 10 PC, it doesn't start. I've used windeployqt, but without success. I have also copied all the C:\Qt\5.9.2\mingw53_32\bin dlls. I've tried with Mingw32 compiler and MSVC2017 64 bits compiler. In both cases the same, on development works well, but not in a clean PC.

    For Mingw32, I've already copied all the C:\Qt\Tools\mingw530_32\bin dlls. For MSVC2017, I've downloaded and installed the redistributable package.

    I have also tried with the gallery sample. Occurs the same.

    K 1 Reply Last reply 11 Oct 2017, 16:05
    0
    • L lqsa
      11 Oct 2017, 14:45

      I've created an application with Qt 5.9.2. On my development laptop, the application works well, but when I try to run it on a clean Windows 10 PC, it doesn't start. I've used windeployqt, but without success. I have also copied all the C:\Qt\5.9.2\mingw53_32\bin dlls. I've tried with Mingw32 compiler and MSVC2017 64 bits compiler. In both cases the same, on development works well, but not in a clean PC.

      For Mingw32, I've already copied all the C:\Qt\Tools\mingw530_32\bin dlls. For MSVC2017, I've downloaded and installed the redistributable package.

      I have also tried with the gallery sample. Occurs the same.

      K Offline
      K Offline
      koahnig
      wrote on 11 Oct 2017, 16:05 last edited by
      #2

      @lqsa

      How do you test on development laptop?
      Always from creator?

      It might be a dumb question, but are you copying also the actual Qt dlls and the Qt plugins?

      Vote the answer(s) that helped you to solve your issue(s)

      L 1 Reply Last reply 11 Oct 2017, 17:09
      0
      • K koahnig
        11 Oct 2017, 16:05

        @lqsa

        How do you test on development laptop?
        Always from creator?

        It might be a dumb question, but are you copying also the actual Qt dlls and the Qt plugins?

        L Offline
        L Offline
        lqsa
        wrote on 11 Oct 2017, 17:09 last edited by
        #3

        @koahnig I've created a separated directory and put there the generated exe and the dlls that needs the application. Doing doble clic, it executes without problems.

        On the clean PC, I've copied the same separated directory. No works. After, I've copied all the QT dlls found on the dirs I've mentioned. No works.

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 11 Oct 2017, 21:34 last edited by
          #4

          Hi,

          What exact modules are you using ?

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

          L 2 Replies Last reply 11 Oct 2017, 22:24
          0
          • S SGaist
            11 Oct 2017, 21:34

            Hi,

            What exact modules are you using ?

            L Offline
            L Offline
            lqsa
            wrote on 11 Oct 2017, 22:24 last edited by
            #5

            @SGaist I've tried with gallery sample and occurs the same.

            I've created a virtual machine with Windows 10 Home. After compile gallery sample with MSVC 2017 64 bit, I've copied the exe and all the dlls inside C:\Qt\5.9.2\msvc2017_64\bin and all the C:\Qt\5.9.2\msvc2017_64\plugins directory.

            On the virtual machine I've installed "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Redist\MSVC\14.11.25325\vcredist_x64.exe".

            Continues the same. On the development laptop works, on the Windows 10 virtual machine, doesn't start.

            1 Reply Last reply
            0
            • S SGaist
              11 Oct 2017, 21:34

              Hi,

              What exact modules are you using ?

              L Offline
              L Offline
              lqsa
              wrote on 11 Oct 2017, 22:29 last edited by
              #6

              @SGaist It's a very basic app, only uses: QT += quickcontrols2

              1 Reply Last reply
              0
              • S Offline
                S Offline
                SGaist
                Lifetime Qt Champion
                wrote on 11 Oct 2017, 22:30 last edited by SGaist 10 Nov 2017, 22:31
                #7

                Did you pass the --qmldir option to windeployqt ?

                [edit: fixed option name SGaist]

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

                L 3 Replies Last reply 11 Oct 2017, 22:37
                1
                • S SGaist
                  11 Oct 2017, 22:30

                  Did you pass the --qmldir option to windeployqt ?

                  [edit: fixed option name SGaist]

                  L Offline
                  L Offline
                  lqsa
                  wrote on 11 Oct 2017, 22:37 last edited by
                  #8

                  @SGaist No

                  1 Reply Last reply
                  0
                  • S SGaist
                    11 Oct 2017, 22:30

                    Did you pass the --qmldir option to windeployqt ?

                    [edit: fixed option name SGaist]

                    L Offline
                    L Offline
                    lqsa
                    wrote on 11 Oct 2017, 22:41 last edited by
                    #9
                    This post is deleted!
                    1 Reply Last reply
                    0
                    • S SGaist
                      11 Oct 2017, 22:30

                      Did you pass the --qmldir option to windeployqt ?

                      [edit: fixed option name SGaist]

                      L Offline
                      L Offline
                      lqsa
                      wrote on 11 Oct 2017, 22:49 last edited by lqsa 10 Nov 2017, 22:57
                      #10

                      @SGaist I've put the --qmldir option on windeploy and the gallery sample works!!!

                      C:\Qt\5.9.2\msvc2017_64\bin\windeployqt.exe --qmldir C:\Qt\5.9.2\msvc2017_64\qml gallery.exe

                      L 1 Reply Last reply 11 Oct 2017, 22:55
                      0
                      • L lqsa
                        11 Oct 2017, 22:49

                        @SGaist I've put the --qmldir option on windeploy and the gallery sample works!!!

                        C:\Qt\5.9.2\msvc2017_64\bin\windeployqt.exe --qmldir C:\Qt\5.9.2\msvc2017_64\qml gallery.exe

                        L Offline
                        L Offline
                        lqsa
                        wrote on 11 Oct 2017, 22:55 last edited by lqsa 10 Nov 2017, 22:57
                        #11

                        @lqsa It works with my app!

                        Thank you very much.

                        1 Reply Last reply
                        0
                        • S Offline
                          S Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on 12 Oct 2017, 07:11 last edited by
                          #12

                          Since you are using QtQuick Controls, you have to also deploy the related libraries/qml files. That's why you should point windeployqt to your project qml folder with the --qmldir option so that it can parse them and deploy the needed dependencies.

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

                          L 1 Reply Last reply 12 Oct 2017, 13:57
                          0
                          • S SGaist
                            12 Oct 2017, 07:11

                            Since you are using QtQuick Controls, you have to also deploy the related libraries/qml files. That's why you should point windeployqt to your project qml folder with the --qmldir option so that it can parse them and deploy the needed dependencies.

                            L Offline
                            L Offline
                            lqsa
                            wrote on 12 Oct 2017, 13:57 last edited by
                            #13

                            @SGaist Sorry, I don't understand your answer. My qmls files are embeded in the application because are treated like resources, so it isn't necessary to copy them. If you see the previous command used, I put on the qmldir parameter the Qt directoy where are the general Qt Qml files.

                            1 Reply Last reply
                            0
                            • S Offline
                              S Offline
                              SGaist
                              Lifetime Qt Champion
                              wrote on 12 Oct 2017, 19:46 last edited by
                              #14

                              It's not about having your qml files deployed it's about having them parsed so the tool can deploy the files from the related modules needed by your qml code to run properly.

                              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

                              3/14

                              11 Oct 2017, 17:09

                              11 unread
                              • Login

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