Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Compiling Qt 5.1.1 static on Windows (XP) with MinGW
Forum Updated to NodeBB v4.3 + New Features

Compiling Qt 5.1.1 static on Windows (XP) with MinGW

Scheduled Pinned Locked Moved General and Desktop
4 Posts 2 Posters 4.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    nando76
    wrote on last edited by
    #1

    Hi friends ;-)

    i am trying to compile Qt 5.1.1 static on my windows xp machine using MinGW.

    my configure.bat call is:
    @configure.bat -static -prefix C:\Qt\5.1.1-static -qt-sql-sqlite -opengl desktop@

    After configure.bat run, i call mingw32-make
    and the after some time compilation aborts with error saying uic.exe is missing the library
    libgcc_s_sjlj-1.dll

    I can not find this library on my machine (i checked also mingw from another installed Qt version)...
    But this library doesn't exists at all ....

    I found some hints to add @-static-gcc -static-g++@
    option into the .pro file...
    But which pro file?
    I added it into the qt.pro file in Qt source folder but without succsess.

    Maybe someone has an idea?

    Greetings,
    Nando

    1 Reply Last reply
    0
    • T Offline
      T Offline
      thEClaw
      wrote on last edited by
      #2

      Back when I was compiling Qt statically, I edited this file:

      qt-everywhere-opensource-src-5.1.1\qtbase\mkspecs\win32-g++\qmake.conf

      and added a "-static" to the following variable:

      QMAKE_LFLAGS

      I haven't tried to compile Qt5 statically, and maybe I changed that file inside the folder containing the MinGW-version I used to compile, not the Qt-sources. So this is only a guess, hope it helps in any way.

      1 Reply Last reply
      0
      • N Offline
        N Offline
        nando76
        wrote on last edited by
        #3

        Thanks !!!!
        That solves the problem! :)

        i just added @-static -static-libgcc@ to QMAKE_LFLAGS in file qt-everywhere-opensource-src-5.1.1\qtbase\mkspecs\win32-g++\qmake.conf

        So the lines looks as follows:
        @QMAKE_LFLAGS = -static -static-libgcc@

        Thank you :)

        [quote author="thEClaw" date="1378358941"]Back when I was compiling Qt statically, I edited this file:

        qt-everywhere-opensource-src-5.1.1\qtbase\mkspecs\win32-g++\qmake.conf

        and added a "-static -static-gcc" to the following variable:

        QMAKE_LFLAGS

        I haven't tried to compile Qt5 statically, and maybe I changed that file inside the folder containing the MinGW-version I used to compile, not the Qt-sources. So this is only a guess, hope it helps in any way.[/quote]

        1 Reply Last reply
        0
        • T Offline
          T Offline
          thEClaw
          wrote on last edited by
          #4

          Happy to hear that still works. :)

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved