When you compile a program with Qt and basically any compiler your program will be dependent on some dlls provided by Qt and the compiler.
For example if you compile a very basic Qt Application that only has a main window and pop up screen with mingw32-gcc-3.4.2 and Qt 4.x.x you would need to distribute the following dlls with your application for it to work on another computer.
I think this is all of them you would need. You might also need another microsoft dll as well. It has been a while since I compiled a program for another comptuer with mingw. But this should give you the basic idea.
mingwm10.dll
QtCore4.dll
QtGui4.dll
For example if I compile with Visual Studio 2005 instead of mingw I might need to distrubute msvcp80.dll with my application instead of mingwm10.dll.
You can use depends.exe to see all of the DLLs your program needs to run. The program can be found here: http://www.dependencywalker.com/
Note that it will show a large list. Most of the DLLs will already be on the target system as they are a part of windows. You will simply need to look for the Qt DLLs and the mingwm10 one. If you forget one when you try running the program on a target machine it should tell you which DLL it can not find.
Also if you never plan on having any kind of plugins or anything for your program you can rebuild Qt in static mode. This will compile everything into the executable (Qt speaking). You will still need to include the DLL from your compiler, however, you will not need to distribute the Qt DLLs as well.
I hope this helps you.




Reply With Quote
Bookmarks