Results 1 to 5 of 5

Thread: How to use QT creator to distribute my application?

  1. #1
    Join Date
    Sep 2010
    Posts
    6
    Thanks
    4
    Qt products
    Qt4
    Platforms
    Windows

    Default How to use QT creator to distribute my application?

    I've read Deploying an Application on Windows (http://doc.qt.nokia.com/4.6/deployment-windows.html)

    However, is there anyway to avoid using command prompt to build QT application statically? instead of using command prompt, can QT creator in anyway build the application statically?

    Like, Do I add -config -static to the qmake build step under is project tab in creator?

    qmake.exe "C:/Users/Weichen/Documents/QT projects/UniqueFactorization/UniqueFactorization.pro" -r -spec win32-g++

    Any help or tutorial would be nice. Thank you.

  2. #2
    Join Date
    May 2010
    Location
    Romania
    Posts
    1,021
    Thanks
    62
    Thanked 260 Times in 246 Posts
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to use QT creator to distribute my application?

    To static build your application you first need to build the Qt libraries static, that's what you need to build from console.

    But check with the LGPL if you don't own commercial license, because LGPL has some restrictions about static builds.

  3. #3
    Join Date
    Sep 2010
    Posts
    6
    Thanks
    4
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: How to use QT creator to distribute my application?

    No one have any idea how to statically build the application just using Qt creator?

  4. #4
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: How to use QT creator to distribute my application?

    Open your *.pro file with the creator, add
    Qt Code:
    1. CONFIG += static
    To copy to clipboard, switch view to plain text mode 
    and recompile your application. (But as Zlatomir mentioned: you must have a static compiled Qt version.)

    And why do you have problems with the command prompt?

  5. #5
    Join Date
    May 2010
    Location
    Romania
    Posts
    1,021
    Thanks
    62
    Thanked 260 Times in 246 Posts
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to use QT creator to distribute my application?

    Quote Originally Posted by Weichen View Post
    No one have any idea how to statically build the application just using Qt creator?
    I don't think that you understand me, so i will try again.

    You need to perform that steps (cmd, configure -static ...other options, nmake/mingw32-make <depending on compiler: VisualC++ or MingW>) to static build the Qt framework (you perform this step once)
    And than (you have Qt build static) you can add that line (the one Lykurg gave you) to your projects that you want to be linked with the static Qt build.
    Hope i said it clearer this time.
    Last edited by Zlatomir; 26th September 2010 at 14:07.

Similar Threads

  1. Conversion from qt creator To application
    By NewLegend in forum Qt Programming
    Replies: 3
    Last Post: 20th September 2010, 22:37
  2. Distribute bandwidth with QTcpSocket
    By danc81 in forum Qt Programming
    Replies: 2
    Last Post: 19th October 2009, 12:17
  3. Replies: 1
    Last Post: 21st May 2009, 22:26
  4. Replies: 2
    Last Post: 1st August 2007, 15:04
  5. Distribute a executable
    By xgoan in forum Installation and Deployment
    Replies: 9
    Last Post: 6th October 2006, 12:51

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.