Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Cross compilation to Windows
Forum Updated to NodeBB v4.3 + New Features

Cross compilation to Windows

Scheduled Pinned Locked Moved Installation and Deployment
3 Posts 3 Posters 2.2k 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.
  • B Offline
    B Offline
    Beberd
    wrote on last edited by
    #1

    Hello,
    I am on linux system and I try to compile my program for windows.
    @qmake -spec win32-g++ -o win32/
    cd win32
    make@

    And I have this error:
    @ -I'/usr/share/qt4/mkspecs/win32-g++' -o release/main.o ../main.cpp
    cc1plus: erreur: unrecognized command line option ‘-mthreads’
    make[1]: *** [release/main.o] Erreur 1
    @

    Could you see where is the problem?

    1 Reply Last reply
    0
    • K Offline
      K Offline
      koahnig
      wrote on last edited by
      #2

      Well, the compiler indicates that the command line option '-mthreads' is not known. You need to find where it is set.

      However, are you sure that it should work that way?
      It looks a bit as you are simply using the win32 compiler settings with your standard linux compiler. AFAIK that is not going to work.

      Vote the answer(s) that helped you to solve your issue(s)

      1 Reply Last reply
      0
      • T Offline
        T Offline
        TioRoy
        wrote on last edited by
        #3

        Some linux distributions have a package named "mingw32-qt" (and others) to cross compile Qt sources.

        1 Reply Last reply
        1

        • Login

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