Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Application doesn't run on other computers [SOLVED]
QtWS25 Last Chance

Application doesn't run on other computers [SOLVED]

Scheduled Pinned Locked Moved General and Desktop
12 Posts 4 Posters 14.1k 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.
  • T Offline
    T Offline
    TwoOfDiamonds
    wrote on last edited by
    #1

    Hello !
    So I created a new version of my application and I ported it to Qt5 . I also use Windows 8.
    The code for my application is "here":http://sourceforge.net/p/captainshutdown/code/ci/master/tree/ .

    The problem is that I can run the application on my pc after I build the release version . However , if I give it to anybody else it won't run ( I put in all the necessary .dlls and resource files in the archive). It will give an "This application requested the Runtime to terminate it in an unusual way." error . Could you give me any hints please?

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

      Any chance of installing an IDE and running your application in debug mode on those other PCs? That would surely help in tracking down the segfault...

      1 Reply Last reply
      0
      • T Offline
        T Offline
        TwoOfDiamonds
        wrote on last edited by
        #3

        Not right now ... not really until I finish with my exams ... I was wondering if it is something that happens a lot ...
        Also... when I run dependency walker it there are few red-written dependencies (I just saw this now)
        IEHIMS.DLL
        API-MS-WIN-CORE-SYNCH-L1-1-0.DLL
        SHCORE.DLL
        SHLWAPI.DLL
        EXT-MS-WIN-ADVAPI32-PSM-APP-L1-1.0.DLL
        IEFRAME.DLL

        Also, these are not found in the Qt directory (at least I haven't found them)

        1 Reply Last reply
        0
        • JKSHJ Offline
          JKSHJ Offline
          JKSH
          Moderators
          wrote on last edited by
          #4

          Hi,

          Dependency Walker doesn't get it 100% right. For example, IEHIMS.dll is NOT required. Furthermore, it doesn't automatically detect DLLs that need to be loaded after the application has started running (libEGL.dll, if I remember correctly)

          Also note that if you compile your application on Windows 8, it probably can't run on Windows XP.

          Read "Creating the Application Package":http://doc-snapshot.qt-project.org/qt5-stable/qtdoc/deployment-windows.html#creating-the-application-package for a list of required DLLs.

          Note also that "This application requested the Runtime to terminate it in an unusual way" could be a sign of a memory bug in your code.

          Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

          1 Reply Last reply
          0
          • T Offline
            T Offline
            TwoOfDiamonds
            wrote on last edited by
            #5

            If it was a memory bug shouldn't it give me the same error on my computer as well?
            And If I compile it on Windows 7 for example does it work on XP and 8 ?
            Also, for win8 ... will it work for any of the earlier versions of Windows ?

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

              Hi,

              The backward compatibility depends on the compiler used. What compiler 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

              1 Reply Last reply
              0
              • JKSHJ Offline
                JKSHJ Offline
                JKSH
                Moderators
                wrote on last edited by
                #7

                [quote author="TwoOfDiamonds" date="1372403692"]If it was a memory bug shouldn't it give me the same error on my computer as well?[/quote]Not necessarily. Since memory is allocated dynamically, the program's memory pattern could be different on different machines.

                Another possibility is that your program is linking to different versions of DLLs on the different machines.

                [quote]And If I compile it on Windows 7 for example does it work on XP and 8 ?
                Also, for win8 ... will it work for any of the earlier versions of Windows ?[/quote]Like SGaist said, it depends. For example, programs compiled with MSVC 2010 will only run on WinXP SP3 and later. Programs compiled with MSVC 2012 will only run on Win7 SP1 and later normally (well, MSVC 2012 can target older platforms too, but some features are disabled. Look up "Platform Targeting").

                Generally, compatibility between Windows 8 and Windows 7 is great, but I'm less certain about Vista and XP.

                If your version of Qt uses ANGLE instead of straight OpenGL, then your program will be linked against the development machine's version of DirectX. Windows 7 and 8 ship with DirectX 11, but Windows XP only supports up to DirectX 9.0c. Programs linked against a newer DirectX won't run on a machine that has an older DirectX, but I think it can work the other way round -- so if you compile on XP I think it should work on Vista, 7 and 8.

                The DirectX restrictions won't be there if you use OpenGL, but the target PCs must have graphics drivers installed that support OpenGL 2.0. The drivers bundled with Windows only support up to OpenGL 1.1 (which is why ANGLE was introduced in the first place)

                Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                1 Reply Last reply
                0
                • T Offline
                  T Offline
                  TwoOfDiamonds
                  wrote on last edited by
                  #8

                  I will try to use VirtualBox and compile it on windows xp . And I hope it will work . Thank for for your in depth answers !
                  I'm using VS2012 and I also have installed QtCreator ... which I think I will remove. I wonder ... how do I know from the first time what .dlls should I include if I use VS2012 ?
                  And what If I install the 32-bit version and use MinGW ?

                  1 Reply Last reply
                  0
                  • T Offline
                    T Offline
                    TwoOfDiamonds
                    wrote on last edited by
                    #9

                    I reinstalled QtCreator and I installed the 32-bit version with MinGW and it works now ! :D

                    Thank you very much for all your answers and help !

                    1 Reply Last reply
                    0
                    • JKSHJ Offline
                      JKSHJ Offline
                      JKSH
                      Moderators
                      wrote on last edited by
                      #10

                      You're welcome :) Glad to hear that it's working for you now!

                      If you still want to read up on deployment and dependencies, here's the "official guide":http://qt-project.org/doc/qt-5.0/qtdoc/deployment-windows.html

                      You can add "[SOLVED]" to your post title by editing the original post.

                      Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                      1 Reply Last reply
                      0
                      • T Offline
                        T Offline
                        TwoOfDiamonds
                        wrote on last edited by
                        #11

                        Ok . I will do that . Also, do you usually use Visual Studio or QtCreator . And why ?

                        1 Reply Last reply
                        0
                        • JKSHJ Offline
                          JKSHJ Offline
                          JKSH
                          Moderators
                          wrote on last edited by
                          #12

                          I usually use Qt Creator, mainly out of familiarity.

                          I started learning C++ through Qt, after a semester of formal education in C (read: using gVim and the console). I tried both VS and Qt Creator at the time. VS was more feature-rich, but I found it overwhelming as a newcomer. In contrast, Qt Creator had a simpler interface and felt less intimidating. So, I started using Qt Creator and gained experience in it, and never found a need to switch to VS.

                          Eventually, I also learnt that Qt Creator provides tight integration with Qt-based projects: Qt Designer (the WYSIWYG widget editor) is integrated into the IDE, and so is the offline Qt documentation. Such integration can only be partially achieved in VS through Qt's Visual Studio Add-In, which only works with paid versions of VS (which I don't have).

                          Once in a while, I'd be asked to work on existing VS-based projects. In those cases, I'd use VS since the solution is already set up. But otherwise, I'm a lot more productive on Qt Creator because I'm much more familiar with it, and because of Qt integration.

                          Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                          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