qt installation (with vs10)

Page  
3

October 24, 2010

jigfjifd jigfjifd
Lab Rat
19 posts

I have added the path C:\Qt\4.7.0 to the qt options in the add in.
The qt keywords are not recognized by VS.

October 24, 2010

Volker Volker
Ant Farmer
5428 posts

What I meant is that you should run the installer for the Visual Studio AddIn, which is completely independent from your Qt library installations (may it be a precompiled or a self compiled one). You can even have multiple versions of the Qt libraries installed and choose which one will be used for your project.

As far as I understood from your previous posts, you should add C:\Qt\4.7.0\qt-everywhere-opensource-src-4.7.0 to the addin. It’s in “Extras” menu (German version, the menu between “Debug” and “Windows”), then “Options…”, then choose Qt.

Then you should follow the steps of the Getting Started guide of the VS Addin Documentation [doc.qt.nokia.com]

October 24, 2010

jigfjifd jigfjifd
Lab Rat
19 posts

I’ve changed C:\Qt\4.7.0\qt-everywhere-opensource-src-4.7.0 to C:\Qt\4.7.0\.
I’ve added C:\Qt\4.7.0 to the add in (which means that in the qt options of the vc addin, in the versions tab, I have a line called : version 4.7.0, path C:\Qt\4.7.0\)
It’s still not working.
The first line of my program is #include <QtGui/QApplication>, but it says the file can’t be found.
Yet I have a file called qapplication.h in C:\Qt\4.7.0\include\QtGui, which contains #include “../../src/gui/kernel/qapplication.h”, and I have indeed a file called qapplication.h in C:\Qt\4.7.0\src\gui\kernel.

October 24, 2010

Volker Volker
Ant Farmer
5428 posts

Did you set up your project using the wizard from “new project” / Qt appplication? If not you must add :\Qt\4.7.0\include to the include path of your project. The wizard adds that for you automatically, AFAIK.

October 24, 2010

jigfjifd jigfjifd
Lab Rat
19 posts

The project had been created with the wizard before the framework compilation which is probably why it didn’t work.
I created a new project, and it works now.
Thanks a lot for your help.

I have one last question that hasn’t been answered yet. Which files/directories were only part of the compilation process and can hence be deleted ?
Thanks.

October 24, 2010

Volker Volker
Ant Farmer
5428 posts

For the previously created project: As far as I know you can set the Qt version to be used afterwards, that should set the appropriate include paths.

You probably can delete the .cpp files. All of the .h files are definitely needed. But I won’t do that. The disk space you gain is not that much and it’s not worth the effort, IMHO. If you really want you can delete the examples subdir, but I won’t do that either, because it’s a good source to sneak how the trolls do certain things :-)

Page  
3

  ‹‹ need help in installing qt mobility      Does Qt 4.6 or 4.7 support postgresSQL 9.0 ? please help ››

You must log in to post a reply. Not a member yet? Register here!