[Interest] Qt 5.12 for Windows (Static)

Nuno Santos nunosantos at imaginando.pt
Wed Jan 23 22:18:14 CET 2019


Michael,

Thanks for sharing your build options. I have been building Qt from source in the last few years with -static -static-runtime enabled without problems. 

We definitely share some configuration details but we couldn’t isolate the cause of this crash yet.

Best,

Nuno

> On 23 Jan 2019, at 16:43, Klank, Michael <Michael.Klank at amk-group.com> wrote:
> 
> I did recently compile Qt5.12.0 static including OpenSSL.
> This is what I do:
> Building OpenSSL:
> set path="c:\Program Files\NASM\";%path%
> perl Configure VC-WIN64A --prefix=c:\OpenSSL\vc-win64a --openssldir=c:\OpenSSL\SSL no-asm
> 
> building Qt:
> SET _ROOT=C:\klm\src\qt5
> SET PATH=%_ROOT%\qtbase\bin;%_ROOT%\gnuwin32\bin;%PATH%
> SET PATH=%_ROOT%\qtrepotools\bin;%PATH%
> set path=c:\Python27\;%path%
> 
> cd c:\klm\src\
> rm -rf qt5
> git clone https://code.qt.io/qt/qt5.git
> cd %_ROOT%
> git checkout 5.12.0
> perl init-repository
> pause
> 
> change inside mkspecs/common/msvc-desktop.conf:
> from QMAKE_CFLAGS_RELEASE    = $$QMAKE_CFLAGS_OPTIMIZE -MD to QMAKE_CFLAGS_RELEASE    = $$QMAKE_CFLAGS_OPTIMIZE -MT
> from QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += $$QMAKE_CFLAGS_OPTIMIZE -Zi -MD  to QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += $$QMAKE_CFLAGS_OPTIMIZE -Zi -MT
> from QMAKE_CFLAGS_DEBUG      = -Zi -MDd  to  QMAKE_CFLAGS_DEBUG      = -Zi MTd
> 
> configure -opensource -confirm-license -static -debug-and-release -release -no-pch -optimize-size -nomake tests -nomake examples -qt-zlib -qt-libjpeg -qt-libpng -opengl desktop -plugin-sql-sqlite -openssl -Ic:/OpenSSL/vc-win64a/include -Lc:/OpenSSL/vc-win64a/lib
> jom
> jom install
> 
> Static debug build with qmldebug enabled doesn_t work. Disable qmldebug and it works for me.
> Hope this helps.
> 
> Michael
> 
> -----Ursprüngliche Nachricht-----
> Von: Interest [mailto:interest-bounces at qt-project.org] Im Auftrag von Nuno Santos
> Gesendet: Mittwoch, 23. Januar 2019 10:44
> An: Thiago Macieira <thiago.macieira at intel.com>
> Cc: interest at qt-project.org
> Betreff: Re: [Interest] Qt 5.12 for Windows (Static)
> 
> Thiago,
> 
> I forgot to mention one small detail. A simple console application works and doesn’t crash. Maybe this has something to do with the Qt Quick engine only. Anyway, I have filled the following bug report:
> 
> https://bugreports.qt.io/browse/QTBUG-73217
> 
> Thanks!
> 
> Best regards,
> 
> Nuno
> 
>> On 23 Jan 2019, at 09:16, Nuno Santos <nunosantos at imaginando.pt> wrote:
>> 
>> Thiago,
>> 
>> Followed as suggested.
>> 
>> 1) removed openssl dependency and tried to compile again -> Didn’t work! :(
>> 2) removed -static and -static-runtime options -> Worked! :)
>> 
>> Maybe there is some kind of issue with -static -static-runtime build options
>> 
>> Will fill a bug report.
>> 
>> Thanks!
>> 
>> Best regards,
>> 
>> Nuno
>> 
>>> On 17 Jan 2019, at 16:35, Thiago Macieira <thiago.macieira at intel.com> wrote:
>>> 
>>> On Thursday, 17 January 2019 05:07:21 PST Nuno Santos wrote:
>>>> Can you spot anything wrong?
>>> 
>>> Reduce your problem. Suggested steps:
>>> 1) remove OpenSSL dependency
>>> 2) use regular dynamic runtime (not -static-runtime)
>>> 3) build your application with fewer Qt libraries
>>> 
>>> What is the smallest combination that still crashes at load?
>>> 
>>> Make sure your application is CONFIG += console, so that any output goes to
>>> the console instead of the debug ring.
>>> 
>>> --
>>> Thiago Macieira - thiago.macieira (AT) intel.com
>>> Software Architect - Intel Open Source Technology Center
>>> 
>>> 
>>> 
>>> _______________________________________________
>>> Interest mailing list
>>> Interest at qt-project.org
>>> https://lists.qt-project.org/listinfo/interest
>> 
>> _______________________________________________
>> Interest mailing list
>> Interest at qt-project.org
>> https://lists.qt-project.org/listinfo/interest
> 
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> https://lists.qt-project.org/listinfo/interest
> 
> ________________________________
> 
> Persönlich haftende Gesellschafterin: AMK Verwaltungsgesellschaft mbH, Kirchheim/Teck
> Geschäftsführer: Rainer Schwöbel, Rupert Wiest
> Registergericht Stuttgart HRB 230208; HRA 230681
> 
> Die in dieser E-Mail enthaltenen Informationen sind vertraulich. Diese E-Mail ist ausschließlich für den Adressaten bestimmt und jeglicher Zugriff durch andere Personen ist nicht zulässig. Falls Sie nicht der beabsichtigte Empfänger sind, ist jegliche Veröffentlichung, Vervielfältigung, Verteilung und sonstige in diesem Zusammenhang stehende Handlung untersagt und unter Umständen ungesetzlich. Falls Sie diese E-Mail irrtümlich erhalten haben, leiten Sie sie bitte weiter an die folgende E-Mail-Adresse: info at amk-group.com
> 
> The information in this e-mail is confidential. It is intended solely for the address and access to the e-mail by anyone else is unauthorised. If you are not the intended recipient, any disclosure, copying, distribution or any action taken or committed to be taken in reliance on it, is prohibited and may be unlawful. If you have received this e-mail in error please forward to this e-mail-address: info at amk-group.com
> 
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> https://lists.qt-project.org/listinfo/interest




More information about the Interest mailing list