views:

502

answers:

2

Hello,

I ve installed QT Creator in OpenSUSE Linux distro, Can i know if it is possible to create ".exe" of QT program which is perfectly executing in Linux.

If so kindly mention the procedure to create .exe in Linux.

Thank U

A: 

I understand that you have a Qt application, and you are able to compile it on OpenSuse using QtCreator, and you want to create a windows binary of the same application on OpenSuse.

The most hassle free method of doing this is to install the Qt SDK (and QtCreator, if need be) and compile your code on a windows machine.

If not, take a look at http://silmor.de/29.

jrh


UPDATE: in response to your comment:

in that case you need to cross compile your code on linux for windows. (you obviously know this, as you have tagged your question well).

  1. You need to install MinGW on linux: http://www.mingw.org/wiki/LinuxCrossMinGW
  2. Now follow the instructions on http://silmor.de/29.

This should be all.

jrh

Here Be Wolves
thanks for ur reply...Actually i want to create .exe in Linux, using which i can directly run my application in windows along with supporting windows binary... i dont want to recompile my code in Windows ...Kindly give ur suggession upon it...
suse
The link which u ve given say abt cross compiling QT/Windows Application on Linux... But i would need to know vice-versa...
suse
Please tel me if QT SDk in Linux , has any option to generate .exe...
suse
Short answer: No. Long answer: No, but you can generate .exe if you follow the steps in the answer.
Here Be Wolves
thanks for info...but a small question..if we have to create .exe in Linux , should i cross compile Linux or cross compile Windows.Pls pls reply... i'm in great confusion.. :(Pls help
suse
Okay, I think some clarification is in order: if you want to create a windows binary (.exe) on any development environment other than one based on Windows, you are cross compiling. Actually the term "cross compile" has come from cross compilation for different hardware platforms, like compiling x86_64 code on an x86 machine.
Here Be Wolves
+1  A: 

Maybe this page could help you?

Makis
The link which u ve given say abt cross compiling QT/Windows Application on Linux... But i would need to know vice-versa
suse
You need to do what the page tells you to. Trust me.
Here Be Wolves