1

I am working on MAC OSX Snow Leopard and I want to deploy my project onto Windows

It is a Qt Desktop app

  1. How do I generate the .exe file (+other dependencies if any)
  2. Any method to package all the .exe + dlls into one package for installation

Note: I would rather not install Qt SDK on windows and copy the project files to it and then build it.

Need solution for 1 and better if you answer 1 & 2 questions

Bart
  • 19,692
  • 7
  • 68
  • 77
Rahul Reddy
  • 128
  • 10
  • Ehm, you take your project and sources to your Windows machine and build your application there? And as for deployment, there is a fair bit of information within the Qt documentation: http://qt-project.org/doc/qt-4.8/deployment.html (including platform specific info) – Bart May 31 '12 at 12:01
  • @Bart I Would not like to do that – Rahul Reddy May 31 '12 at 12:02

2 Answers2

7

The first step is relatively easy.

Go here http://crossgcc.rts-software.org/doku.php and grab a precompiled MinGW package (or looks for the mingw-w64 package at sourceforge and compile it yourself if you need to produce 64-bit executables).

Then compile all the dependencies you need (or use the prebuilt win32 libs).

At last, use the makefiles to build win32 executable on your MacOSX machine.

The second step - that depends. I haven't heard of any packagers for OSX capable of producing .msi or .exe installer, but it does not mean there aren't any. Maybe some kind of cross-compiled NSIS might help (but if this depends on WinAPI heavily at least WINE libs would be required).

EDIT: looks like building NSIS is a viable option for packaging the installer on OSX.

Viktor Latypov
  • 14,289
  • 3
  • 40
  • 55
  • Thanks for that , installed the MinGW on OSX but when i compile the Program i am getting errors as it cannot find the QT dll , can u give the procedure for compiling using MinGW – Rahul Reddy May 31 '12 at 13:55
  • I've build my own projects (OpenGL-based) using this exact MinGW build. However, I'm not an expert in Qt. You say that you're using the .dll. Then try to find the Qt export libraries for mingw. – Viktor Latypov May 31 '12 at 14:05
2

Ok after few days of searching and tweaking i compiled a solution for my problem and written in most concise form for my fellow friends who are stuck in similar situation , visit Here

You would need

  1. mingw-get-inst
  2. Qt libraries 4.8.2 for Windows (or Higher Version)
  3. Your .proj file (Associated .ui, .cpp, .h etc)

and its a two stage procedure , initially you need to download and install above listed 1 and 2 and setup the required environment and then make and build on the targeted windows system

Rahul Reddy
  • 128
  • 10