You should not run qmake -project multiple times. The -project parameter -project intended to provide you with a template project file for editing. The equivalent of what you do in the IDE will create a “New Project” every time you want to build. After the initial project, you have to edit it manually, add files when you have new files, etc. If any header file changes, the generated Makefile will notice it and call moc to update the moc _ * file. Cpp automatically. So:
- Run
qmake -project when you start work on the project. - Run
qmake if you want to create Make files. - Run
make when you want to create a project.
source share