PDA

View Full Version : Make Clean not working as in previous version of QTcreator



emp1953
14th December 2020, 17:13
I am using QtCreator 4.11 and Qt5.8.
I've created a makefile using qmake projectname.pro. when performing a make clean, the executable is not removed. All the other files that should be removed are removed, but the executable persists. What is the setting that I have to make to get this to perform as it did before.

Also, when I build in QtCreator using the first green arrow on the lower left it does not run the executable. The previous version would compile then run the new executable. I'm sure its another project setting, can anyone give me some insight.
Thanks

ChrisW67
15th December 2020, 07:36
When performing a make clean, the executable is not removed. All the other files that should be removed are removed, but the executable persists.
Correct. The clean target removes intermediate objects, temporary files, and core files, not the executable.


clean: compiler_clean
-$(DEL_FILE) $(OBJECTS)
-$(DEL_FILE) *~ core *.core




What is the setting that I have to make to get this to perform as it did before.
The distclean target also removes the target executable/library, the qmake.stash file, and the Makefile.


distclean: clean
-$(DEL_FILE) $(TARGET)
-$(DEL_FILE) .qmake.stash
-$(DEL_FILE) Makefile


This boilerplate qmake output has not changed for as long as I can remember.

emp1953
15th December 2020, 15:36
Very Helpful indeed. I don't recall ever using that dist clean method before.

How do I mark this solved, for when someone tackles the 2nd question on the post.

Is there something to click on here to Thank or give points or something?

ChrisW67
17th December 2020, 08:41
There is no Solved button. There is a Thanks button at the bottom of each post.

Regarding the Qt Creator question. It depends on why it is not running.
It may be failing to find the executable to run. Check your project configuration:
13583

It may be attempting to run the program, but the program does not find dependencies and terminates. You can set a library search path in the same area of the project configuration.

If all else fails try closing Qt Creator, removing the yourproject.pro.user file, and reimporting the PRO file into a new project.