Friday, July 4th 2008, 8:55pm UTC+1

You are not logged in.

  • Login
  • Register

1

Tuesday, August 15th 2006, 12:34pm

problem compiling "hello world" with qt4

hi!
i can't compile my first qt program, the "hello world" included on the QT assistant.

qmake -project : no problem
qmake: no problem
make: i get the following error:

Source code

1
2
main.cpp:1:24: error QApplication: Can't find the file
(the same with QPushButton)

(well, i use it in spanish, so it may be a little different).


I use Kubuntu 06.06. Installed the QTs with synaptic, so i supone there are no problems with the packages installed. Just in case, these are all i have: qt3-apps-dev, qt3-assistant, qt3-designer, qt3-dev-tools, qt3-doc, qt3-examples, qt3-lynguist, qt3-qtconfig, qt4-designer, qt4-dev-tools, qt4-doc qt4-config,

i've tried some of the things i read in this forum, but none worked. Anyway, i am quite newbie using linux, so i supose the problem has a trivial solution.

thanks for your help,

manuel

This post has been edited 1 times, last edit by "supermanue" (Aug 15th 2006, 12:34pm)

  • Go to the top of the page

2

Monday, September 11th 2006, 9:43pm

Well your QT files are not where it should be.

Try this:

Source code

1
equery files qt | grep lib


Source code

1
equery files qt | grep include

If you do not have include program, install it!


Then compile with options to this two directories.
  • Go to the top of the page

Atil

Beginner

Posts: 36

Location: India

Occupation: R & D

3

Thursday, November 15th 2007, 8:34am

RE: problem compiling "hello world" with qt4

in debian machines, you have to write down

#include <QApplication> only instead of QApplication.h

and put this line in your .pro file

CONFIG += Qt
  • Go to the top of the page

Rate this thread