Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You should build Qt with the MinGW compiler you're using to build your application. GCC is generally less sensitive to binary compatibility issues than MSVC is, but Qt is a big, complex framework library. If anything would expose those kinds of issues, Qt would probably be on the short list.</p> <p>Building Qt is pretty straightforward, but it takes a lot of time and there always seems to be two or three patches I need to make to get things to build successfully.</p> <p>The last time I built Qt (4.7.3) with MinGW, I had to make the following patches - I'm not sure whether they will still apply to Qt 4.8:</p> <ul> <li>make sure not to enable C++11 mode in the compiler - there are several macros with concatenated string literals that break under the new C++11 extended literal syntax</li> <li><p>there is a problem with how some distributions of MinGW incorporate the Microsoft extensions to <code>float.h</code> - I had to sometimes had to add the line:</p> <pre><code>#include_next &lt;float.h&gt; </code></pre> <p>to the end of the MinGW-specific <code>float.h</code> so the generic GCC <code>float.h</code> would get processed properly. I had to do this for nuwen 4.7.0 <code>lib/gcc/i686-pc-mingw32/4.7.0/include/float.h</code> and TDM 4.6.1 32-bit distro <code>lib/gcc/mingw32/4.6.1/include/float.h</code> (the 64-bit distro of TDM didn't need this patch).</p></li> <li><p>patch <code>qmake\Makefile.win32-g++</code> and <code>qmake\Makefile.win32-g++-sh</code> to remove the <code>-static-libstdc++</code> option that GCC doesn't recognize (and now errors out on instead of ignores)</p></li> <li><p>patch <code>mkspecs/win32-g++/qmake.conf</code> to move the <code>-Wl,</code> in the <code>QMAKE_LFLAGS_EXCEPTIONS_ON</code> macro to its proper place in <code>QMAKE_FLAGS</code>:</p> <pre><code>QMAKE_LFLAGS = -Wl,-enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-reloc QMAKE_LFLAGS_EXCEPTIONS_ON = -mthreads </code></pre></li> <li><p>copy <code>make.exe</code> to <code>mingw32-make.exe</code> in MinGW's <code>bin</code> directory if there's not already a <code>mingw32-make.exe</code></p></li> </ul> <p>Then building Qt consists of:</p> <pre><code> set QTDIR=&lt;location of Qt source directory&gt; # where configure.exe is set PATH=%QTDIR%\bin;c:\MinGW\bin;%PATH% set INCLUDE= set LIB= cd %QTDIR% mingw32-make confclean # (this should fail the first time, since there's nothing to clean) configure.exe -opensource -debug-and-release -nomake examples -nomake demos -nomake tests -platform win32-g++ # and accept the GPL license mingw32-make </code></pre> <p>This takes a while... hopefully nothing else will need patching.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload