'Add *filename* as a dependency of the current document.
This means that the document will be rebuilt if this file changes.
*filename* should be absolute or relative to the source directory.'

def note_dependency(self, filename):

    self.dependencies[self.docname].add(filename)
