Hi,
GCC has an option to generate depfiles using a Makefile-like syntax. For instance:
// foo.c
#include "bar.h"
If you call gcc -MMD foo.c, it'll generate the following file:
ninja supports reading those depfiles and converting them to ninja's internal dependency format, and meson lets you specify a "depfile" argument to e.g. custom_target() or generator().
— eli-schwartz
I'm using meson to describe the build of my project and I have a few files to be processed through re2c. Some of the files use the /*!include:re2c "my-re-defs.re" */ re2c's syntax and it'd be nice to have them automatically rebuilt when the included file changes. The build system can take care of this if re2c accepts an option to generate a second output (the depfile). Can we have an option to build a depfile alongside the main output?
Hi,
GCC has an option to generate depfiles using a Makefile-like syntax. For instance:
If you call
gcc -MMD foo.c, it'll generate the following file:— eli-schwartz
I'm using meson to describe the build of my project and I have a few files to be processed through re2c. Some of the files use the
/*!include:re2c "my-re-defs.re" */re2c's syntax and it'd be nice to have them automatically rebuilt when the included file changes. The build system can take care of this if re2c accepts an option to generate a second output (the depfile). Can we have an option to build a depfile alongside the main output?