3 ms·
> I also feel like good makefiles are usually very small and dont need much tweaking once they are in place. This only works for small projects. Once your proj
by e63f67dd-065b 2y ago
> I also feel like good makefiles are usually very small and dont need much tweaking once they are in place.
This only works for small projects. Once your project grows beyond a handful of files and dependencies this breaks down real fast.
I've been on this train more than once: most non-trivial projects reach a point where you have to build for multiple targets, support multiple configurations, test in all those weird configurations, manage CI, manage external dependencies, build said dependencies, etc. A makefile that supports all of the above becomes a monstrosity long before you get there and at some point you give up and pull in a real build system to take care of it (they're all bad in their own way, pick your poison really with cmake/meson/bazel/<new shiny thing>, just less bad than make).
Sure you can manage a giant pile of target-specific variables, platform-dependent scripts, and what not in make, but really it's much less painful to just bite the bullet and migrate to a build system that thought of these problems before. Things like "this dependency is mandatory is this configuration, optional in these other configurations, and is liked differently depending on whether we're building static or shared objects and whether we're using the platform library or falling back to a vendored version" is basically impossible in my experience.
Makefiles are great when your project is a dozen `.c` files. The moment you grow beyond that it's time to move on and use something else.
- pheggs 2y ago[dead]