mozilla/dxr — pull request #121 by abbeyj (2013-04-05 19:37:30+00:00)
Title: Incremental build support

This is a preliminary change for suggestions. It does the following:
1) Adds a new --incremental option that doesn't delete the temp and object directories
2) Keeps a list of all .csv files generated for each output file in .lst files (suggestions for a better extension?)

Instead of reading in *.csv we now read in *.lst and then read in all the .csv files mentioned within each one (skipping duplicates). This handles the case where we modify a header or source file. Old .csv files will still be left around but they won't be read in and so won't pollute the index. It also handles the case where we delete a header file and remove all references to it.

It does have a problem with a source file that is completely deleted (or renamed). The generated data for old version will still be read in and this might cause issues. To work around this I'm thinking that we'd need to grab a list of all files that are eventually passed to the linker and then create a list of the corresponding .lst files. I'm not sure how easy it would be to get that information? Does clang have plugin support for that? Do we need to handle both the case where the build calls $(CXX) for linking and the case where it directly calls $(LD) itself?