Support building with --disable-maintainer-mode and source != build dir (#3518)
Before adoption: this commit came in with the history the project adopted, so no landing records it.
If --disable-maintainer-mode is enabled, then the rules for generating parser.[ch] and lexer.[ch] did nothing. This worked fine if the source and build directories are the same as the pre-generated parser.c and lexer.c files would suffice. However, if the build directory is not the same as the source directory, then the rest of the Make rules expect parser.[ch] and lexer.[ch] to have been created in the build directory if their source files (parser.y and lexer.l) are newer than the target files, which can happen in case the source is fetched using Git. Avoid the problem by copying the files to the build directory if needed.
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Trailers
- Co-authored-by: Peter Kjellerstedt <pkj@axis.com>
Diff stats
1 file+7 added−2 removed
- other:+7 added−2 removed