Most IDEs (Integrated Development Environments) provide smart dependency checking; that is, they automate the task of finding these dependencies and propagating the recompilation when an application is rebuilt.
In this paper we study the problem of extracting dependency information from Java sources and propose an encoding of these dependency information as regular expressions. This encoding is both compact to store and fast to check.
Furthermore, our technique detects a particular kind of dependencies, which we call ghost dependencies, that popular tools, even commercial ones, fail to detect. Because of this failure, some required recompilations are not triggered by these tools and the result of their incremental recompilations is not equivalent to the recompilation of all sources.