Portable Static Windows QT build



  • My particular configuration is Win-7 32-bit with Qt 5.1.1and mingw32. I have read the topics and found a series of DOS style commands that should create a Static build for my configuration, and have used Qt to make an EXE build. However, both of these methods require the distribution of compiler specific DLLs. Does Qt support any means for me to create an all inclusive (e.g. Portable) release? I am writing free programs (e.g. pill, appointment and phone call reminders) for the elderly and clicking an EXE is all I can, and should, expect of the users. I prefer Portable to minimize any installation or support issues (these will be free programs after all). If this is only possible with a pro version of VC++, or something else, then I will buy it. I just need a solution and any guidance would be appreciated.


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    AFAIK, you can achieve that by modifying the mkspec changing the MD to MT to link to the static VS runtime. Disclaimer: I never tried it and it also locks you to this runtime and can interfere with the use of other libraries.

    Just out of curiosity, wouldn't your target audience need to somehow install the program ? In that case you can use an installer and keep using the dynamic build.



  • Thank you for your reply. It appears that you feel switching to VS may be my only answer but are unsure since you have not tried this. I am hoping for a known solution. Use of an installer is problematic and, in some cases, will not be an option. I need PORTABLE.


  • Lifetime Qt Champion

    Sorry, my bad, I have overlooked the mingw32 in your post. I haven't built
    a static Qt with mingw yet.

    But you might be interested by "this guide":http://qt-project.org/wiki/How_to_build_a_static_Qt_version_for_Windows_with_gcc



  • Thank you, but I am looking for a PORTABLE build, not static. Does anyone know of a solution?


  • Lifetime Qt Champion

    Then I'm not sure I'm following you right, can you define more precisely what you mean by "portable build" ? Or how you would use that build ?



  • As noted in my original post "an all inclusive (e.g. Portable) release". This means a single EXE with everything required for it to run without any installer or permanently changing their computer. You may learn more by reading about Qt Creator portables. (http://portableapps.com/node/19930). However, teaching what a portable application is, is off topic from my question of how to build a portable Qt application.

    Does anyone know of a solution?


  • Lifetime Qt Champion

    Then I understood you right. That's generally why one uses a complete static build: to avoid the need of separated ell's. But still, there are licensing issues with a Qt static build.

    Anyway, I think your are looking for the "Windows deployment guide":http://qt-project.org/doc/qt-5.0/qtdoc/deployment-windows.html which explains the steps needed to make your application run on another computer without the need to install Qt SDK etc...


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.