Newbie Makefile and qtquick2applicationviewer problem
I am having a problem which I think may be related to a previous install of a Blackberry Playbook-specific build of Qt.
I installed, wasted a lot of time on, then uninstalled "Qt-4_8_0-PlaybookSDK.exe" (I don't remember where I got this from as it was some time ago now).
Anyway, yesterday I downloaded and installed Qt 5.0.2 mingw version. I was following the "Transitions" tutorial, but when it came to running it for the first time, I received the following message:
@18:15:50: Running steps for project Transitions...
18:15:50: Configuration unchanged, skipping qmake step.
18:15:50: Starting: "C:\Qt\Qt5.0.2\Tools\MinGW\bin\mingw32-make.exe"
mingw32-make: *** No rule to make target '../Transitions/qtquick2applicationviewer/qtquick2applicationviewer.pri', needed by 'Makefile'. Stop.
18:15:51: The process "C:\Qt\Qt5.0.2\Tools\MinGW\bin\mingw32-make.exe" exited with code 2.
Error while building/deploying project Transitions (kit: Desktop Qt 5.0.2 MinGW 32bit)
When executing step 'Make'
18:15:51: Elapsed time: 00:02.@
This raised some questions with me - like where is the Makefile? I searched my filesystem (I'm running Windows 7 64-bit) for qtquick2applicationviewer, but drew a blank. I'm at a loss as to where this is coming from?
I tried uninstalling Qt, removing the "C:\Qt" directory and performing a fresh install. Interestingly, after doing this Qt still somehow remembered my previously opened projects, so I presume there are some additional settings being stored somewhere. Perhaps this is at the root of my problems, but I am not sure where these settings would be stored ("User<username>\AppData ..." Perhaps)?
Any pointers on where to go from here would be gratefully appreciated.
Thanks in advance,
qtquick2applicationviewer is automaticaly generated by Qt Creator when you start new QtQuick2 project and is part of project. But your compiler cannot find it. Maybe you can try to create an empty project and copy qtquick2applicationviewer into project you are trying to build.
Hi portolst, thanks for the reply. Unfortunately, I can't find any files called qtquick2applicationviewer on my computer, which is why I'm confused.
The other reason I'm confused is that I can't find a Makefile, so I don't even know where the information in the Makefile is coming from.
I don't know the Transitions tutorial you are refering to.
Are you trying to build your app from Qt Creator? If so check your project settings in Qt Creator. You can find directories where your app will be build for release and debugging in there. Makefile should be located in these directories.
Thanks for the advice portoist!
Perhaps we are a little closer to understanding - in the Makefile, there is a reference to:
However, when I look in the "Transitions" directory, there is no "qtquick2applicationviewer" - what I do see though, is:
I'm guessing this is the same (or a similar) viewer, but was renamed for Qt5.
The question is, why do I still have the reference to the old "viewer" even though I have uninstalled and re-installed Qt Creator. Sure, I can hack the Makefile for now, but that's a workaround rather than a solution...
Having typed that, I wonder if the problem is in mingw? Hmmm...
Nope! I just checked and mingw is installed here:
and the contents of C:\Qt are wiped when uninstalling, so it is still a mystery to me!
The "viewer" is part of project, reinstalling Qt Creator has no effect on it. Hacking Makefile will not solve anything, as it is generated by qmake. You can however simply get qtquick2applicationviewer. In your Qt Creator go to file->New file or project->Qt Quick2 Application (Built-in Elements) and create some temp project. Qt Creator will generate qtquick2applicationviewer dir with files in this temp project. You can then copy the qtquick2applicationviewer directory into Transitions directory.