Can't compile Qt project
I installed the Qt libraries and wrote a small sample program, but when I try compiling it it does this:
Code:
$ qmake -project I wonder what's the problem? This is the code: Code:
#include <QApplication> |
Quote:
|
|
Quote:
and check this folder /usr/include/qt3. and isn't there a official or none-official qt package for your system? |
I installed like this, just like you said (Note that I shut down the computer between the two, make took longer than I expected and it was quite late by then, but I don't think this could have affected anything):
Code:
$ make |
I dont know anything about Qt, but use these instead of the headers you have (which, as the compiler says, dont exist)
Code:
#include <qapplication.h> |
Same thing.
But anyway it shows the headers capitalized everywhere. |
No, it doesnt.
Apparently Qt 4 uses what you had in your first post (see http://doc.trolltech.com/4.0/tutorial-t1.html). However, your using Qt 3 which does what I suggested (see http://doc.trolltech.com/3.0/tutorial1-01.html). Make sure you followed the steps for Qt 3, for installation, configuration, compiling, etc, as it seems you followed the Qt 4 Hello World tutorial its possible you followed the Qt 4 version of other steps. |
Quote:
and MTK358, i tried it with QT4 and it worked. maybe you are using wrong version of qt to compile. qmake -v should show you the QT version and where it is. you are trying to complite it with QT3. |
Quote:
|
Quote:
and definitely she is using wrong QT version. |
But the page where I downloaded it says Qt4!?!
Anyway it didn't work and then I tried apt-get install qt-dev*, maybe that's the problem. Also I am going to get openSUSE 11.2 tomorrow, and I hope to install it instead of Debian. I would really want to know how to install Qt4 (not 3) correctly there and have it work. But it would be nice to get some Qt practice on Debian toworrow while waiting for the approximately 4.7GB download. I see you are wondering whether I am a "he" or a "she", I am a "he". |
It does work Qt3 style.
|
Quote:
|
Yes. At least for Qt3, as far as I know.
|
All times are GMT -5. The time now is 11:53 AM. |