Skip to content
Prev 200353 / 398503 Next

How to generate dependency file that can be used by gnu make?

gcc has options like -MM, which can generate the dependence files for
a C/C++ file that I can be used by gnu make. I'm wondering if there is
a tool that can generate dependence file for an R script.

For example, I have an R script test.R

#########test.R
load('input.RData')
save.image('output.RData')


I want to generate a dependence file like the following. Is there a
tool to do so?

output.RData:test.R input.RData