Cross compilation to Windows
-
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?
-
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. -
Some linux distributions have a package named "mingw32-qt" (and others) to cross compile Qt sources.