I don't know how to do that and suspect that it cannot be done. BUT if your higher goal is to find the files referenced by the warnings it may be enough to use Emacs:
Open a file in the top source directory, like C-x C-f configure.ac RET
, run the compilation: M-x compile RET
(possibly edit the make
command) RET
. When you see a warning in the compilation buffer, use C-x backtick
(C-x `) to display the source location.
Emacs manages this by parsing the "Entering directory /foo" and "Leaving directory /foo" messages from make
so you may want to emulate that.