Unsolved I still cannot figure out why my programs do not work on other people's computers.
-
A day ago I made a thread saying that I was having trouble getting my program to work on other people's computers due to an error that said it could not find the windows platform. A few people responded with someone suggesting I use windeloyqt to fix the problem of the missing platform. I did that and that fixed the problem sort of, but introduced a new problem in that even if people had the redistributibles, they still could not run it.
I'm left to wonder if I messed something up in running windeloyqt or if it's just a bug. Either way, I need to fix this for future projects that use Qt. Here is the link to the other thread about this topic: (https://forum.qt.io/topic/68973/application-not-running-on-other-people-s-pcs/2)
-
As Mr. @mrjj suggested , did you kept all dll in the .exe folder (in build folder)? Copy the dll'S from here C:\Qt\5.5\msvc2013_64\bin Eg: (Qt5Core.dll .... all ) to the folder where your .exe is there. Don't MIX debug and Release.
-
@Ni.Sumi As you can see in the picture, I'm using the release DLLs. I'm using Qt 32-bit DLLs as I'm making a x86 app not 64. Here is what is in the release folder. (http://puu.sh/pSnLJ/de46cba6be.png)
-
Okay, Please make it sure, that you don't need other dll'S? like Qt5OpenGL.dll ,... Qt5Network.dll like this.
you can use dependencywalker to find the needed dlls.
-
@Ni.Sumi Did not know about this, thanks. Will look at it and see what I can do.
-
@Ni.Sumi Okay, running dependencywalker I got all these errors: (http://puu.sh/pSpjq/9ee75bd8b3.png) what do I do?
-
Look for required Qtxxxx.dll in the main tree. Like this
And check in your .exe folder that you have all the required dll' or not.
-
@ProgrammerAtHeart3344
Another tip i often use to find out dependency libraries is to start application in debug mode from Qt Creator and to look at Modules panel. You can see there some Qt libraries and also plugins libraries you use in application. -
Hi,
Which modules are you using in your application ?
-
@SGaist Is there a way to check that without making a new project? Because honestly, I'm only using the bear minimum, that's all.
-
@SGaist Sorry for double post but here is what dependency viewer says: (http://puu.sh/pSOjh/a00f43b23c.png) . Also, I deleted everything in the folder, rebuilt the application, and did windeployQt over again. I would need someone to test it though....However, since the content of the app is meant to be a jab at a certain person, I'm not sure it would be appropriate to share that on this forum. As much as I love to mess around, I don't know anyone on here so I don't want to offend anyone. Call it professionalism on my part.
So I'm not sure what to do. Is it normal for all these modules to give errors? Should I be worried about the potential health of my PC? Also, I don't think I've mentioned I was using windows 10 before, did I?
-
Wouldn't you be building a 32bit package and try to run it using the 64bit runtime ?
By the way kernel32 and shell32 are system libraries, don't copy them.
-
Just as a matter of interest what does your friends windows error dialog show when your app fails to run?
Does it indicate which dlls it cannot find? -
I saw the screen shot in your other post and wondered if you are still seeing those error dialogs?
I use windeployqt all the time on windows with no problems. I use windows 10 too but my programs run on lower versions of windows if the correct windows redists are installed.
-
The screen capture of the dependancy walker showing all the missing 'API-MS-WIN-CORE-XXX.DLL's probably means you didn't install the necessary redistributable file(s) on the target computer. Each version of Visual Studio will have their own run time distributable that you need to send with your application. You must install this if it is missing on any computer you intend to run your application.
If you have a problem with this (meaning it would be preferable not to install anything on the target computer) then one option is to use the Qt/MinGW combination. I am in a situation where installing anything on a computer necessary to run any applications is not an option so using Visual Studio is out of the question (unless there is a way around this problem?). Most places I visit will allow user-level access to the computer and they are okay with running in-house software but installing anything is usually forbidden.
The only downside with using MinGW is your application will be 32 bit. There is a MinGW64 that you could potentially use but you will need to set this up yourself, compile your own version of Qt, and so on. The upside of MinGW versions of your application is it will work on any computer (Vista -> Win10, potentially Win2000/WinXP if your careful on how you compile Qt) without any hassels. You still need to include all the necessary DLL's and plugins but it appears you have this part already.