Results 1 to 4 of 4

Thread: QT Applicaton installation

  1. #1
    Join Date
    Mar 2010
    Posts
    107
    Thanks
    22
    Qt products
    Qt4
    Platforms
    Windows

    Default QT Applicaton installation

    Hi all
    So I have my QT application (written on a windows platform using Eclipse and the MinGW toolchain).
    Now I have to distirbute this to my clients who may have a MAC or Linux or Windows box.
    What i am looking for is some advice on how this is normally managed. My clients are not usually 'computer savvy' so would expect some sort of installer program.
    Is there an installer that can deploy to all platforms or will I need one for each?
    What are other peoples experiences of this

    TIA

    Graham

  2. #2
    Join Date
    Jul 2008
    Location
    London, UK
    Posts
    11
    Thanked 5 Times in 5 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: QT Applicaton installation

    Yup. They all tend to require a different approach.

    The standard Mac way to ship your app is as a DMG (disk image) file - when that is "mounted" by the OS it will appear in Finder - the preferred mechanism is to show your application (.app file) and a link to "Applications" with a background image telling the user to drag the app to the applications folder to install it. Have a hunt through the "Disk Utility" documentation. Other options are programs like iDMG, EasyDMG etc.

    Windows - good grief - there are MANY options - All I'll say is I've tried 4 or 5 and always end up coming back to Nulsoft NSIS http://nsis.sourceforge.net/ . It's fairly simple and has a good community of users so web searches will usually tip up and answer in one or another forum. There are lots of sample files and the format for install scripts is raw text so it works nicely with source control systems.

    Linux - blimey - here I will bow to someone with more knowledge than myself. The ultimate answer would be to package your application (rpm, deb etc) but that is a mystery to me. Another approach is to actually write an application that is shipped as an executable binary and then proceeds to copy files to where they need to go.

    burnttoy.

  3. The following user says thank you to burnttoy for this useful post:

    GrahamLabdon (25th October 2010)

  4. #3
    Join Date
    Jan 2010
    Posts
    40
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QT Applicaton installation

    As someone who has just written a cross platform Qt app, I can address a few of your questions. First off, you can't just distribute your program to folks running a different OS. Windows executables will not simply run on Mac or Linux boxes natively. Qt is write once, compile anywhere, not compile once run anywhere. Big difference. Forgive me if you already know this, but the wording of you opening sentence led me to believe you didn't.

    I can't give advice about Mac, since what I know about that platform will fit into a thimble, but I'm pretty handy with the other two. First up, Windows. I don't know about NSIS, but I have successfully used a program called Inno for years. It has good documentation, the scripts are written in plain text, and has a lot of advanced features. You can create and modify registry entries, register DLL and OCX files, install custom fonts, etc. It produces a single setup exe that the users can easily walk themselves through.

    Next up, Linux. I don't know if Eclipse and/or MinGw can cross compile and produce a Linux executable, but even if it can, I don't recommend it unless you want your users to end up in dependency hell. You will want to set up some sort of Linux development environment, and install Eclipse on it. Then, you will want to package your app. The two most common package formats are deb, used by Ubuntu and other Debian based distros, and rpm, used by Fedora, Mandriva, and other Red Hat offshoots. Do a Google search on creating rpm or deb files for a lot of good info, or you can use a program called Debreate. It will walk you through the process of creating a deb package, and even has a utility to convert it to an rpm. It does assume you have a basic knowledge of what is in a deb file, so you should read up a bit on that. Also, before packaging a Linux app, you will want to get the dependency info. Compile your app with Eclipse, and run a utility called ldd. This will give you dependency info for your app, which you can include in the package you create. This will allow the package management system on the target computer to resolve all dependencies automatically.

    Sorry if I rambled on. Let me know if there is anything in this post that is unclear.

  5. The following user says thank you to skepticalgeek for this useful post:

    GrahamLabdon (27th October 2010)

  6. #4
    Join Date
    Mar 2010
    Posts
    107
    Thanks
    22
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: QT Applicaton installation

    Excellent advice - thanks

Similar Threads

  1. Qt 4.6.1 Installation
    By JulioCastro in forum Newbie
    Replies: 2
    Last Post: 5th February 2010, 07:36
  2. Qt for s60 installation
    By addu in forum Installation and Deployment
    Replies: 2
    Last Post: 26th August 2009, 11:37
  3. help me with the installation of QT 4.4.1
    By kernel19 in forum Installation and Deployment
    Replies: 1
    Last Post: 14th September 2008, 15:13
  4. Dev-C++ & Qt4.4 installation
    By Colx007 in forum Installation and Deployment
    Replies: 2
    Last Post: 24th May 2008, 09:56
  5. Installation
    By sanwar in forum Installation and Deployment
    Replies: 4
    Last Post: 11th October 2006, 16:11

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
  •  
Qt is a trademark of The Qt Company.