I'm having troubles with QLabel. This is the code from the book :
Qt Code:
  1. // helloWorld/main.cpp
  2. #include <QApplication>
  3. #include <QLabel>
  4.  
  5. int main(int argc, char *argv[])
  6. {
  7. QApplication a(argc, argv);
  8. QLabel label("Hello World");
  9. label.show();
  10. return a.exec();
  11. }
To copy to clipboard, switch view to plain text mode 
main.cpp:2:24: error: QApplication: No such file or directory
main.cpp:3:18: error: QLabel: No such file or directory
main.cpp: In function 'int main(int, char**)':
main.cpp:7: error: 'QApplication' was not declared in this scope
main.cpp:7: error: expected `;' before 'a'
main.cpp:8: error: 'QLabel' was not declared in this scope
main.cpp:8: error: expected `;' before 'label'
main.cpp:9: error: 'label' was not declared in this scope
main.cpp:10: error: 'a' was not declared in this scope
main.cpp: At global scope:
main.cpp:5: warning: unused parameter 'argc'
main.cpp:5: warning: unused parameter 'argv'
make: *** [main.o] Error 1

Than I change in header QApplication to qapplication.h and QLabel to qlabel.h
Qt Code:
  1. // helloWorld/main.cpp
  2. #include <qapplication.h>
  3. #include <qlabel.h>
  4.  
  5. int main(int argc, char *argv[])
  6. {
  7. QApplication a(argc, argv);
  8. QLabel label("Hello World");
  9. label.show();
  10. return a.exec();
  11. }
To copy to clipboard, switch view to plain text mode 
main.cpp: In function 'int main(int, char**)':
main.cpp:8: error: no matching function for call to 'QLabel::QLabel(const char [12])'
/usr/lib/qt/include/qlabel.h:163: note: candidates are: QLabel::QLabel(const QLabel&)
/usr/lib/qt/include/qlabel.h:66: note: QLabel::QLabel(QWidget*, const QString&, QWidget*, const char*, uint)
/usr/lib/qt/include/qlabel.h:64: note: QLabel::QLabel(const QString&, QWidget*, const char*, uint)
/usr/lib/qt/include/qlabel.h:62: note: QLabel::QLabel(QWidget*, const char*, uint)
make: *** [main.o] Error 1

Can somebody tell me what is wrong with this?