Most complex software projects are compiled using a build tool (e.g. make), which runs commands in an order satisfying userdefined dependencies. Unfortunately, most build tools require all dependencies to be specified before the build starts. This restriction makes many dependency patterns difficult to express, especially those involving files generated at build time. We show how to eliminate this restriction, allowing additional dependencies to be specified while building. We have implemented our ideas in the Haskell library Shake, and have used Shake to write a complex build system which compiles millions of lines of code. Categories and Subject Descriptors D.3 [Software]: Programming Languages General Terms Languages Keywords build-system, compilation, Haskell