CMake unconfigured on fresh Qt Creator installation on OS X
-
I work on a Mac (OS X 10.11.6) with Xcode (8.2.1) installed. I have just uninstalled a previous Qt Creator installation (my old Qt folder is gone). Now, I have a fresh installation created by qt-unified-mac-x64-2.0.4-online.
To test the installation, I immediately opened Qt Creator and picked File|New project. Thus I created a Qt Console Application with nothing but the default contents.
Now when I check the project in Qt Creator's 'Projects' page, where I click 'Manage Kits', I see the yellow-triangle exclamation marks both on the 'Auto-detected' kit (named 'Desktop Qt 5.7.1 clang 64bit') and on the two Manual kits (named 'Desktop (default)' and 'Desktop').
When I hover the mouse on the 'Auto-detected' warning, it says in the pop-up window:
Desktop Qt 5.7.1 clang 64bit
Warning: CMake configuration has no CMAKE_PREFIX_PATH set that points to the kit Qt version.
QT version: Qt 5.7.1 clang 64bit
CMake: Unconfigured'What is wrong, I just installed Qt Creator?
I have worked with Qt Creator on Windows for 20 years. In Windows I have always used the MinGW toolset, compiler and all. I notice that on both OS X and Windows, when I open the 'CMake' tab under 'Build & Run', it is blank for both 'Auto-detected' and 'Manual'.
Is the problem on my Mac, that either my Xcode or Qt Creator installation is not complete? I mean, is CMake part of the Xcode or Qt Creator installation? Or should Cmake be installed seperately? Finally, I guess there must be some other make software installed with Xcode, so I could maybe just configure my project to work with that instead of CMake?
-
Hi and welcome to devnet,
CMake comes with neither. You can install it through e.g. macports/homebrew/insert_other_package_manager_name_here or get a pre-build binary package directly from the CMake site.
-
@SGaist I find it weird that the Qt Creator installation for OS X defaults to CMake, when CMake is not part of the installation. You could of course say the same about its dependence on Xcode; however, Xcode is indispensable. CMake, in contrast, is not.
I can build my project with Qt Creator on OS X even without CMake. I wonder which make software it is using then? Something that came with Qt Creator or with Xcode? And, then again, why isn't that make software the default when it is already available?
How do I change my project to not refer to CMake but rather to the make sofware, that it is clever enough to use any how? The current project setup with all its warning seems untidy and fragile to me. - Thanks!
-
Might be an old settings you had from before. I don't know.
Qt Creator comes with no such thing by default. It's an IDE.
Qt itself uses qmake as project manager. Then depending on your tastes you can use it or, CMake or QBS or even plain old autotools.
Did you install Qt Creator as standalone or as part of a standard Qt install through the online or offline installer ?
-
@SGaist I am well aware that Qt Creator is just an IDE but when you use the online installer (as I did) you get a choice between various toolsets, that you may want to use the IDE to operate on.
I chose Clang because I thought that Clang was part of the Xcode package. That way I would not have to download yet another software. But I might have been wrong. If Clang is part of CMake (?) all of this makes sense to me.
Yet, Qt Creator does, in fact, build my code. Which compiler is it using if not Clang? And how can I tell Qt Creator to stop looking for CMake?
-
That warning is not about cmake, but about the cmake configuration: That has changed a while back and the old values are now flagged as a warning to draw attention to that change.
Feel free to ignore this warning if you do not plan to use cmake.
If you want to get rid of that warning: Go into the CMake Configuration settings of the kit and hit "Reset" there. This change may potentially change the results of building a cmake project. I do not want to have creator do such a change behind the back of the user. This way -- if the build changes -- at least the user will be aware that his cmake configuration has changed and knows where to undo that change again.
-
That's it! And I managed to fix the CMake issue too as per your guidence.