The Ninja Generator has logic to fall back to SCons to produce generated sources that are produced via "template" like mechanisms that are available only to SCons, most notable SubstFile.
The current ninja generator neglects to declare that these files depend on their inputs. As a result, if, say wiredtiger.h.in is itself updated, SCons will not be re-invoked by the generated Ninja file to produce an updated wiredtiger.h
The fix is to include the source files as dependencies of the generated templates.