PDA

View Full Version : Problem building Qt project



almo
3rd August 2012, 20:34
I was just given a project folder with a Qt project in it. I've built stuff with Qt before on my computer, so the QtSDK is installed in the usual place: C:\QtSDK

When I try to build this project, I get this error:

Error: dependent '..\..\..\QtSDK\Desktop\Qt\4.8.1\msvc2008\mkspecs\ win32-msvc2008\qmake.conf' does not exist.15:30:25: The process "C:\QtSDK\QtCreator\bin\jom.exe" exited with code 2.

I do have version 4.8.1, and the qmake.conf in question exists.

Looking in the Makefile, I see these hardcoded ..\..\..\ dependencies. I don't see them anywhere in Qt Creator. So at this point, I am not sure what my next step is. I've tried a few things like deleting the Makefile to see if it's rebuilt, with no luck.

Naahmi
4th August 2012, 09:55
Hello,

do you have set the QTDIR enviroment variable correct?

And why is a space is the path? "\mkspecs\ win32-msvc2008\qmake.conf'"

almo
6th August 2012, 15:32
I do not appear to have a QTDIR env var set, at least not in the Windows control panel that shows env vars. The space is apparently from the copy/paste from the QT Creator's error box, so that doesn't appear to be the issue. I'll see about getting that env var set right.

ETA: I just found out that when I made my own Qt project a few months ago, I did it through Visual Studio. So I tested Qt Creator by trying to run one of its sample projects, and it says that it can't find "qmessageservice.h". So I think it's the env var thing. Will see about fixing that.

ETA: Projects->Build Steps has a thing for additional arguments. It was set to

-spec ../../../qtsdk/desktop/qt/4.8.1/msvc2008/mkspecs/win32-msvc2008

Changing that to ../../../../qtsdk... fixed it.

dnyt4y21
10th August 2012, 04:37
"\mkspecs\ win32-msvc2008\qmake.conf" remove the space and then will work.