4 ms·
I once used gmake to implement a multi-stage Mechanical Turk workflow. It was awful. The syntax sucks. But it worked consistently, and the core logic was only
by sehugg 14y ago
I once used gmake to implement a multi-stage Mechanical Turk workflow.
It was awful. The syntax sucks. But it worked consistently, and the core logic was only 110 lines of Makefile. It described the files and the data flow between them. Even now, I can read it and understand it with not too much effort.
Make is a very simple functional language. It's restartable. If you type 'make -j 2' it becomes parallelizable. For almost anything for which you might write a shell script, you have to ask yourself: Why not make instead?
I would like a cleaner, kinder make, but I also want it to retain make's essential make-iness. Nothing else seems to do that.
I do feel bad for anyone downstream of my makefiles, though.
- tiziano88 14y agoactually, why not a shell script?
- sehugg 14y agoShell scripts are fine, but if your shell scripts generate files than makefiles might help you model the dependencies between them. You get parallel execution and restart ability almost for free. (and they detect errors a little better)