I've been working on a large Xcode project for a while now, and one of the things that I've run into is rebuilds getting triggered when a file is touched, but its contents are not modified.
The reason is that
llbuild considers several
fstat values when determining whether a file was modified.
This is also the practice in several other well-known build systems, such as
make, but some have claimed that it might be harmful.
Cases when using modification time produces a false positive:
- Git operations
- Code getting regenerated by a script
- Accidentally typing a character and then deleting it
What do you think? I've done a quick experiment and it seems that using an MD5 hash of the file instead is possible!