Re:Using Make – writing less Makefile
by dpkirchner on Tuesday December 26, 2023 @03:58PM
(#38775992)
The biggest practical difference is that make can test to see if a file needs to be rebuilt before proceeding.
[ Parent
| on HN ]
Yes, exactly this.
When compiling a project once from a clean state make has no advantage over a shell script that would use a tool like "parallel" to distribute compilation jobs over all available CPU cores.
However writing such a script for parallel compilation is more complex than writing a simple Makefile executed with "make -j N".
As you say, the main reason of existence of "make" is the acceleration of the recompilation of a project after incremental changes in the source files, when only the files that depend on the changes are recompiled, saving time.