[Qt-creator] Package All Dependencies option for Release Mode
Sarah Hollings
sarah.hollings at gmail.com
Wed Feb 4 02:28:33 CET 2009
For Mac OSX the .pro build automatically creates a Mac OSX bundle. With the
line:
ICON = DndToolD20.icns
and a suitably created .icns file containing the icon set, they are also
added to the bundle by a normal build. Nice.
I then have a script that can create a redistributable by adding in all the
libraries to the bundle:
http://code.google.com/p/dndtool/source/browse/trunk/DndTool/build_bundle.sh
I typically run this from the command line.
But you can easily add "install" as an argument to make - "Projects" view,
build settings tab, build steps for active build, select "Make" and add
"install" to the arguments.
That way your build also runs the install, completing the distributable. Or
you could create another build, and select it when needed with right-click
on the project, "Set Build Configuration".
Something for windows in your .pro might look like:
nsis.command=/path/to/nsis.bat
win32:INSTALLS += nsis
I don't have access to Windows at present so check the qmake manual.
On Wed, Feb 4, 2009 at 5:58 AM, Charles N Burns <charlesnburns at gmail.com>wrote:
> Though not as convenient as integration, if you compile Qt static yourself,
> this can probably automated by adding a custom build step (projects -> Build
> Settings -> Build Step) which runs a batch file that does the qmake, make,
> and strip. Might have to echo "CONFIG += staticlib" to the pro file as well.
>
> I say "probably" because I haven't done this yet.
>
> The same idea could be used to copy the appropriate DLL files, though for
> both the step would likely have to be added to each and every project.
>
> In the long-run, I think it would be great to have a wizard-like compile &
> package process which would ask the user whether to package the program as
> an "install.exe"/"install.dmg" of some kind, a .MSI (for the Windows build),
> a zip/tarball with the necessary libraries included, or a statically-linked,
> optionally stripped single executable file.
> Unfortunately, making this work appropriately for every platform might be a
> big project.
>
> --Charles Burns
>
>
>
> On Tue, Feb 3, 2009 at 8:22 AM, Yonnys Pablo Martin Olivera <
> ypmartin at uci.cu> wrote:
>
>> Or the option for build the project with static link to library and
>> without dependency of external (QtCore4.dll | libqtcore4.so)
>>
>> Ing. Yonnys Pablo Martín Olivera
>> Universidad de las Ciencias Informáticas
>> http://primavera.uci.cu/proyectos/qmasc
>>
>>
>>
>> -----Original Message-----
>> From: qt-creator-bounces at trolltech.com on behalf of Michael Pearce
>> Sent: Tue 03.02.2009 11:19
>> To: Qt-creator at trolltech.com
>> Subject: [Qt-creator] Package All Dependencies option for Release Mode
>>
>>
>> Hi,
>>
>> It would be really useful if, when building a Qt Creator project in
>> release mode, you had the option to package up all of the dependencies into
>> a single directory with the executable so that you didn't have to go copying
>> QtCore4.dll, etc., find the correct version it's linking to, etc., etc.
>>
>> Or does such a thing exist already?
>>
>> -Michael
>>
>>
>> _______________________________________________
>> Qt-creator mailing list
>> Qt-creator at trolltech.com
>> http://lists.trolltech.com/mailman/listinfo/qt-creator
>>
>>
>
>
>
> --
> "Be who you are and say what you feel, because those who mind don't matter
> and those who matter don't mind." --Dr. Seuss
>
> _______________________________________________
> Qt-creator mailing list
> Qt-creator at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-creator
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-creator-old/attachments/20090204/30b81c4a/attachment.html
More information about the Qt-creator-old
mailing list