[Qt-interest] Compiling Into a Monolithic Executable

Malyushytsky, Alex alex at wai.com
Sat Mar 28 23:59:56 CET 2009


On the Windows (at least with msvc) this will not work.
Problem is C runtime libraries.

QT 4.4.3 and as I was told 4.5 does not support linking to static C libraries.
I was able to build it but it had problems when run.

I have a commercial support which told it is not supported right now and this may be changed in the future.

Regards,
    Alex

-----Original Message-----
From: qt-interest-bounces at trolltech.com [mailto:qt-interest-bounces at trolltech.com] On Behalf Of Vincent L. Damewood
Sent: Saturday, March 28, 2009 5:36 AM
To: Raja Sekharan
Cc: qt-interest at trolltech.com
Subject: Re: [Qt-interest] Compiling Into a Monolithic Executable

2009/3/28 Raja Sekharan <websweetweb at gmail.com>:
> Hi,
> I would like to compile my application into a single executable file in
> Linux and Windows. The executable should run regardless of what library is
> installed or not in the Local linux system. Is there a way to do this? I
> understand that compiling in windows already creates a completely self
> contained executable but how do I do the same with Linux.
> Raja Sekharan

Configure qt with -static and make sure that the gcc gets the -static
argument when linking.

Linking information for gcc:
http://gcc.gnu.org/onlinedocs/gcc/Link-Options.html
_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest


---------------------------------------------------------------------------------------------------
Weidlinger Associates, Inc. made the following annotations.

"This message and any attachments are solely for the intended recipient and may contain confidential or privileged information. If you are not the intended recipient, any disclosure, copying, use, or distribution of the information included in this message and any attachments is prohibited. If you have received this communication in error, please notify us by reply e-mail and immediately and permanently delete this message and any attachments. Thank you."

"Please consider our environment before printing this email."




More information about the Qt-interest-old mailing list