PDA

View Full Version : Compile Qtcreator with mingw ?



tonnot
3rd November 2010, 12:09
I have finally discovered that if I want to use custom widgets I must to compile QTcreator with Mingw.
Anyone can give some indications ?
I have downloaded de source from QT, but I dont know how to do.
Must I open qtcreator.pro and compile it ?
Thanks

saa7_go
3rd November 2010, 12:25
Open "Qt Command Prompt" and change directory to Qt Creator source directory.
Then execute :
> qmake
> mingw32-make release

tonnot
3rd November 2010, 16:00
After (I suppose) finished the work, I have explored the main folder and see some files and subfolders that has been created.
Where is the new Qtcreator ? how many folders I need ? What folders at the original QT I must rewrite ?
If I run the new QTCreator.exe (located at \bin
Failed to load core \lib\qtcreator\plugins\Nokia\Core.dll >> Not find ?
( And this file really exists )
I'm completely lost...

saa7_go
3rd November 2010, 16:21
Maybe, there is conflict with other Qt Creator. BTW, did you run 'mingw32-make clean'?

tonnot
3rd November 2010, 16:33
mmmmmm
I'm going to do all again.
But, Why QT people compile qt creator with msvc and Qt designer with mingw ?????

wysota
3rd November 2010, 16:42
After (I suppose) finished the work, I have explored the main folder and see some files and subfolders that has been created.
Where is the new Qtcreator ? how many folders I need ? What folders at the original QT I must rewrite ?
If I run the new QTCreator.exe (located at \bin
Failed to load core \lib\qtcreator\plugins\Nokia\Core.dll >> Not find ?
( And this file really exists )
I'm completely lost...

Set the INSTALL_ROOT environment variable to the directory where you want to install Creator to (like C:\QtCreator_2.1) and run mingw32-make install.


But, Why QT people compile qt creator with msvc and Qt designer with mingw ?????

Because Designer is part of Qt release (which is compiled with MinGW) and Creator is part of the "Qt Creator" release which is built with msvc. Glued together this gives "Qt SDK".

tonnot
3rd November 2010, 17:31
Can be so :

qmake
mingw32-make release install

And,
1.- If I set INSTALL_ROOT, how it can affect to QT operation?
2.- Anyway to indicate this place to mingw32 install command ?
(mingw32-make release install:"c:\qtcreator")


Wysota, first thanks for the answer. I dont understand your explanation about the compilers used. Would not it be better than the two will use the same compiler?
Thanks.

wysota
3rd November 2010, 17:41
Can be so :

qmake
mingw32-make release install
This is immediately incorrect. Unless of course you set INSTALL_ROOT prior to running qmake.


And,
1.- If I set INSTALL_ROOT, how it can affect to QT operation?
I have no idea what you mean.


2.- Anyway to indicate this place to mingw32 install command ?
(mingw32-make release install:"c:\qtcreator")
Read my previous post again.


Would not it be better than the two will use the same compiler?
If they feel more comfortable with msvc then why shouldn't they be using it? What's the difference which compiler they use?

tonnot
3rd November 2010, 18:14
I have search 'INSTALL_ROOT' at google. At the moment I dont know if this variable is used by QT or Mingw.
At QT Help the only link I can to find is : Installing Qt on Embedded Linux
So, I think that I can set the variable for this work (compile Qt Creator) and forget it , isn't ?


If they feel more comfortable with msvc then why shouldn't they be using it? What's the difference which compiler they use?
Because if I'm going to develop a custom widget with plugin aproach, If I have QT Creator (MSVC) , and build my plugin using mingw... (I have not MSVC of course).
I think the most of people uses one 'system' : all based in MSVC or Mingw, isn't ? So it would be interesting that QT offer a mingw or msvc based bin distribution ...

wysota
3rd November 2010, 18:21
I have search 'INSTALL_ROOT' at google. At the moment I dont know if this variable is used by QT or Mingw.
Let me repeat myself:
Set the INSTALL_ROOT environment variable to the directory where you want to install Creator to (like C:\QtCreator_2.1). In doubt open the Makefile and analyze it yourself.

Since you wanted to be treated as a mature developer I'm sure you know what environment variables are and how to use them.


Because if I'm going to develop a custom widget with plugin aproach, If I have QT Creator (MSVC) , and build my plugin using mingw... (I have not MSVC of course).
I think the most of people uses one 'system' : all based in MSVC or Mingw, isn't ?
So you say Qt Creator should be built with MinGW so that people using MinGW wouldn't have to rebuild it but instead people using MSVC or any other supported compiler would, is that correct? So what's the difference?

By the way, you already have Qt built for MSVC if you install Qt SDK, since Creator needs it so it is provided in the installation package. Or you can download it separately and build the things you need with MSVC Express. Choose the approach you find most appropriate.

tonnot
3rd November 2010, 18:27
But... (And I consider closed this post) I think that if you have QTcreator (MSVC) and build a widget plugin with msvc you can not use it with QT designer .
So the cuestion is everybody must to build something.... ?

wysota
3rd November 2010, 18:39
I think that if you have QTcreator (MSVC) and build a widget plugin with msvc you can not use it with QT designer .
So the cuestion is everybody must to build something.... ?

To be honest, I don't know. I use the bleeding-edge version of Creator anyway, so I have everything built myself with one compiler (on Linux) unless I only need the basic functionality of the sdk (on Windows) where I don't use Designer at all (unless I'm testing whether wwWidgets work but then I don't need Creator). There always comes a moment when you need to grow beyond the rigid and minimalistic cage provided by the default setup of practically anything.

tonnot
3rd November 2010, 20:43
Sorry, but I keep on getting nothing....
I have a .bat (placed at the qtcreator source - at my d: drive) with this content :

SET INSTALL_ROOT = d:\QT2
qmake
mingw32-make release install

I run this bat ... and there is no d:\QT2
Please, any tutorial ?

wysota
3rd November 2010, 22:00
Please, any tutorial ?
http://www.google.com/search?q=setting+environment+variables+on+windows