Is there a standard sequencing idiom to make it so "make -jN clean all" works, i.e. so all can't start creating files concurrently with clean deleting them (among other issues)?
Conversation
Replying to
I use `make -B` for this rather than clean. I find that I'm almost always doing it to work around unstated dependencies such as changes to environment variables, upgrades to the OS toolchain, etc. It would be nicer to track those implicit dependencies but I haven't bothered.
1
2
I think it would help to have the recipes in the Makefile depend on the Makefile itself along with outputting relevant environment variables to a file overwritten when a change occurs and having that as a dependency too. Could also depend on executables for all tools being used.
1
Still not going to be perfect, and it has never bothered me enough to actually deal with it, but I've thought about making a reusable approach I could copy across projects so that I wouldn't have to use `make -B` nearly as much as I end up using it. Annoys me to need it at all.

