I'm writing a Makefile and these are the clean and cleanall targets
clean:
$(RM) *.o
cleanall: clean
$(RM) $(TARGETS)
I have to use this on both linux and MacOs. When I compile on mac, in the process some folders with a dSYM extension are created and so I need to delete them too.
Is there a way to make the cleanall target delete those folders, but only if called on a mac?
I was looking for something like an if then else
option but I found nothing.