3 ms·
As an actual builder it has limitations, such as not having (built in) the ability to know if it can still do an incremental build after changing some build opt
by ajb 2y ago
As an actual builder it has limitations, such as not having (built in) the ability to know if it can still do an incremental build after changing some build option. That can result in inconsistent builds.
The main problem is that you often require more logic than makes sense to write in make, but it kind of has a language built into it so people try to use it. But as a language it's terrible (no scoping, many missing features). So people end up implementing their build logic in a bastard combination of make and shell which is very opaque and difficult to debug.
For example, I was recently trying to figure out how the OpenWRT makefiles are doing something, and it was really painful, because with make having no scoping any part of the system could end up affecting the piece you are looking at. There is a lot of dropping into shell to get stuff done, and a lot of the targets are themselves expanded variables, which makes it really opaque. Really a lot of it is not gaining from being written in make, they could do with rewriting large parts in a real language. But it would be a huge job. And that's where a lot of makefile systems end up
That's why you get tools like ninja where they decided not to allow any logic at all.
- eru 2y ago> That's why you get tools like ninja where they decided not to allow any logic at all. Or you get shake, where your logic is the logic of a real programming language.