NEW: Guide for manual app deployment on Windows
-
Thanks, good initiative !
-
Thanks, SGaist :)
The page has been updated with a diagram. Hopefully this will clear confusion on where to put plugins.
-
The picture should be indeed very helpful. That would be an interesting addition to the documentation
-
I'll submit the picture to the official docs after the dev -> stable merge happens for Qt 5.3.
I've verified that this layout works for both Windows and Linux (just swap .dll for .so). Is it the same on Mac?
-
Mac is a complete different beast but it has macdeployqt that should take care of this for the user
-
I appreciate the effort of making this guide, but looks to me like a way too long, risky and almost impossible to achieve process. Think about a very huge application where a particular DLL might only be needed if the user reaches a rare end point (like settings in settings dialog windows), it would drive crazy the developer(s) on testing every single QPushButton they have and the other widgets...
So, I was wondering, wouldn't it be possible to identify the needed DLLs by knowing the headers and modules used in a project? I am thinking at a header-to-DLL tree where the user can identify the most likely needed DLLs. For example, if the core and network modules are used it's most likely that the application requires at least Qt5Core.dll and Qt5Network.dll.
At the moment I don't have a clue on how to go further into this, but this:
http://qt-project.org/forums/viewthread/36786/
might be a start point.
What do you think ? -
Hi T3STY,
Thank you for your suggestions.
First, let me explain my motivation for writing this guide. I wanted to address 3 major problems regarding app deployment:
Developers are often frustrated because they can't get their app to launch.
Developers often put DLLs in the wrong subdirectories.
On the forums, the same questions are being asked and answered over and over again.
The guide contains a big diagram with very simple instructions ("Copy everything from these 3 folders!"). It deals with (1) and (2) very quickly, thus relieving (3).
Overall, this guide aims to save time for everyone -- users who're trying to deploy their apps, and users who're trying to help others deploy correctly.
[quote author="T3STY" date="1392612725"]I appreciate the effort of making this guide, but looks to me like a way too long, risky and almost impossible to achieve process. Think about a very huge application where a particular DLL might only be needed if the user reaches a rare end point (like settings in settings dialog windows), it would drive crazy the developer(s) on testing every single QPushButton they have and the other widgets...[/quote]I don't think it's that impossible. I used this technique to deploy my last 3 apps, and it worked nicely on both Windows and Linux.
Anyway, what you described is a common problem faced by test engineers. People can't test everything, so they test the most important parts only. If a missing DLL is only required by a rarely-used section, then most end-users might not even be affected. When someone does encounter the issue, they can file a bug report.
[quote]So, I was wondering, wouldn't it be possible to identify the needed DLLs by knowing the headers and modules used in a project? I am thinking at a header-to-DLL tree where the user can identify the most likely needed DLLs. For example, if the core and network modules are used it's most likely that the application requires at least Qt5Core.dll and Qt5Network.dll.
At the moment I don't have a clue on how to go further into this, but this:
http://qt-project.org/forums/viewthread/36786/
might be a start point.
What do you think ?[/quote]I tried to do that at first, actually. I agree that it would be very nice to have a definitive list of DLLs!But it turned out to be an steep uphill struggle. Firstly, Qt has so many modules... and more are added with each minor release. It would take forever to identify the DLLs that are required by each feature, and the list would need to be updated every time a new feature is released.
Secondly, the dependencies aren't always obvious. e.g. My QML multimedia app required Qt5Widgets.dll.
Thirdly, the dependencies vary depending on package and OS. e.g. A TCP-based app requires Qt D-Bus on Linux, but not on Windows. There might be differences between ANGLE and OpenGL packages (but I haven't tested for any).
I think manually creating this header-to-DLL tree is possible, but the end benefits don't justify the effort required. If someone has the patience to achieve that, or if someone can write a program to generate the tree automatically, then I salute them. But, I personally can't do that. :)
-
I understood why it would be hard. But, I wasn't asking for you to do this job alone. I was thinking about a team working on it, one module at a time, even if it is going to take a long time to finish it. After we'll have completed most of the modules we would only have to maintain the newly added modules. I know we'll be unable to identify exactly all the libraries that might be required (the OS-specific ones would be a headache), but we surely can identify most of them, which makes it quite a nice work. Also, if any Qt devels could get in touch with the team, they would be of great help.
Anyway that's just a thought that requires some people who have some spare time to work on it.
p.s. Please note that i wasn't really criticizing your work, and I'm still thankful for that guide!
-
Sorry for the late reply!
I think the most sustainable way to do this would be to create an automated script that can detect the required libraries, but I don't know where to start on that.
A large collaborative group can work too. the Wiki seems like the most logical place to collect manual work. Would you like to kick-start the effort? I'd be happy to contribute little findings here and there, but I'd prefer to spend most of time on other tasks.
P.S. I see; sorry for the misunderstanding :D Thank you for your kind words!
-
Kick-start the effort? I'd love to, but not at this time. I'm attending university, I'm right in the middle of too much work and I would be totally unable to either start the project or contribute to it. But if you or someone else can make it happen I'd be very glad to give you any help on that whenever I can.
Don't misunderstand me, it's not that I had the idea but I don't want to make it happen. ATM I've got way too little time even for my own day to day life, and it would be impossible for me to keep up all the work and studies I have to do... sorry guys. But let me know if you're up to anything!