When building a project using CMake, an error occurs when generating the target
-
I've previously built four or five projects for learning with no problems, and today, about three or four days apart, I've noticed that no matter how I recreate a new project, it shows an error:
:-1: error: [CMakeFiles\apptest.dir\build.make:88: apptest_qmltyperegistrations.cpp] Error 1
This is the CMake I installed:
This is the CMake configuration:
How to resolve this error message?
-
I've previously built four or five projects for learning with no problems, and today, about three or four days apart, I've noticed that no matter how I recreate a new project, it shows an error:
:-1: error: [CMakeFiles\apptest.dir\build.make:88: apptest_qmltyperegistrations.cpp] Error 1
This is the CMake I installed:
This is the CMake configuration:
How to resolve this error message?
-
You did not answer the question. I know that you installed CMake provided by the Qt installer. But the question is: do you also use it? Check the Kit you're using: which CMake executable is selected there?
-
Please do try to install "Ninja" from the Qt SDK or from https://github.com/ninja-build/ninja/releases. Make sure that you Kit has the "Ninja" generator selected for the CMake generator.
Then do a clean build of your application. (Build > Clear CMake Configuration and afterwards Build > Run CMake)
-
You did not answer the question. I know that you installed CMake provided by the Qt installer. But the question is: do you also use it? Check the Kit you're using: which CMake executable is selected there?
-
Please do try to install "Ninja" from the Qt SDK or from https://github.com/ninja-build/ninja/releases. Make sure that you Kit has the "Ninja" generator selected for the CMake generator.
Then do a clean build of your application. (Build > Clear CMake Configuration and afterwards Build > Run CMake)
@cristian-adam Thanks, I'll try your solution.