You're using make to run a bunch of tasks, including where tasks may depend on other tasks having been run before.
A task-runner tool like `just` is better suited to this task. https://github.com/casey/just
`just` has some nice UX improvements over `make`. (e.g. doesn't require soft tabs, can list recipes out of the box, recipes can take command line arguments, supports .env files, can be run from any subdirectory).
> You're using make to run a bunch of tasks, including where tasks may depend on other tasks having been run before.
And the cool thing is....it works for both!
It can represent an actual file (e.g. a compiled binary) or abstract result (e.g., a successful test).
Make is a tool to make files based on dependencies
It was not created as a scripting language. It understands trees.
It is not to “make” your project. It “makes” “files”
Seems like useful information to me....
It's best practice, though the only time you need it is when a virtual target happens to have the same name as an actual file.
Unless the question was, why do I have to mark targets as PHONY more generally.
In which case the answer is, you don't. You only do this when you want the recipe to always run when invoked, as opposed to the standard mode where invocation is conditional on the file being out-of-date.
(The answer is Bazel, but if you think Make is a "supercar".......)