Hacker News new | ask | show | jobs
by hybridtupel 4236 days ago
Looks quite promising! But: "It will sniff out all of the objects which also need to be built to make it work, and it will build them first." Seems like every source file will always be compiled regardless whether it has changed since the last build or not. So it's just for rather small projects.
2 comments

Hi, thanks for checking it out. I had no idea this would be found all of the sudden. I haven't actually thought about this in a while (I just use it now... it's just another tool for me...) so bear with me here.

It won't rebuild stuff that already exists. Once it decides that it needs to make foo.cc and foo.h into foo.o, it won't recompile foo.o unless foo.cc or foo.h changes... or one of its source dependencies changes.

It's something like this: take all of the timestamps for all of the inputs and outputs for any given target. The oldest output has to still be newer than the newest input. If any input is newer than any output, then we need to build.

It sounds weird, but if you write it out like a number line it makes sense.

Maybe it compares output file timestamps against input file timestamps to decide whether to re-build, as make does? It's hard to figure out details like this without either documentation or source.
Used in conjunction with ccache, this may not matter too much.