August 9, 2011

Sasler Sasler
Lab Rat
3 posts

Qt Creator and Harmattan Application template

 

Whenever I create a new project using the Harmattan Application template in Qt Creator I get “no such file or directory” warnings on #include. For example:

  1. #include <QtGui/QApplication>
  2. #include <QtDeclarative>
  3.  
  4. int main(int argc, char *argv[])
  5. {
  6.     QApplication app(argc, argv);
  7.     QDeclarativeView view;
  8.     view.setSource(QUrl("qrc:/qml/main.qml"));
  9.     view.showFullScreen();
  10.     return app.exec();
  11. }

As you can see, this is the default main.ccp when using the template. But in my case both of the [B]#include[/B] have a green underline with the “no such file or directory” warning. When I run the app on my N950, it works fine, but the actual coding is annoying since auto-complete and stuff doesn’t work properly.

I’m running the latest Qt Creator with latest updates. I’ve just uninstalled and reinstalled everything, but nothing changed. I’ve also tested this on two different computers (albeit both running Windows 7 64 bit) with the same results. But both of the computers have the “Auto-detectQt in PATH” as “not found”.

Does anyone else have the same problem? And, more importantly, does anyone know have a solution to fix this issue?

Cheers :)

4 replies

August 9, 2011

kkrzewniak kkrzewniak
Lab Rat
218 posts

Have you tried adding a Qt version other than Auto-detect? You should have a Harmattan Qt version in the manual section.

Use LINUX :) <- joke

 Signature 

Me, Grimlock, not “nice dino”. ME BASH BRAINS!

August 9, 2011

Sasler Sasler
Lab Rat
3 posts

kkrzewniak wrote:
Have you tried adding a Qt version other than Auto-detect? You should have a Harmattan Qt version in the manual section.

Use LINUX :) <- joke

I have these two for Harmattan:

  1. Harmattan Platform API  (Qt SDK)
  2. c:\qtsdk\madde\targets\harmattan-platform-api\bin\qmake.exe
  3.  
  4. MeeGo 1.2 Harmattan API (Qt SDK)
  5. c:\qtsdk\madde\targets\harmattan-nokia-meego-api\bin\qmake.exe

These came in the default install. That is, I didn’t add them myself.

As for the LINUX, I would use it, but I heard that it’s full of viruses and stuff… :P

August 9, 2011

Eddy Eddy
Area 51 Engineer
1295 posts

have a look at this how to [developer.qt.nokia.com] .

 Signature 

Qt Certified Specialist
Qt Ambassador

August 9, 2011

Sasler Sasler
Lab Rat
3 posts
Eddy wrote:
have a look at this how to [developer.qt.nokia.com] .

Well I’m doing pretty much that, except that I’m using the N950 hardware.

 
  ‹‹ error QT 4.6.2      [Solved]Link errors with Qt Creator on C++ examples out of the box ››

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