I have a Makefile that defines a .PHONY clean target for cleaning up .o files and executables, that target looks like:
... .PHONY : clean clean: rm $(add
Use rm -f (or even better $(RM), provided by built-in make rules, which can be found out using make -p) instead of rm in your cleanrule.
rm -f
$(RM)
make
make -p
rm
clean