Just out of curiosity, how does Makefile know that a file changed (and then recompile it)? Is it up to make
? Is it up to the compiler? If so, is it language dependent?
It looks at the file time-stamp - simple as that. If a dependency is newer that the target, the target is rebuilt.