Makefile: Support 'make tags' and 'make cscope'
Phil Sutter
reviewerPATCH 1/1 Makefile: Support 'make tags' and 'make cscope'
Copy necessary bits from generated Makefile.in into the static extensions/GNUmakefile.in so it plays nicely when called.
For some reason, using 'make ctags' creates a top-level tags file which does not include others, so not quite useful. Using 'make tags' instead works, but only after I created an etags-wrapper (calling ctags -e) in my ~/bin. Seems as per design, though.
--- .gitignore | 3 ++ extensions/GNUmakefile.in | 66 +++++++++++++++++++++++++++++++++++++-- 2 files changed, 67 insertions(+), 2 deletions(-)
.gitignore +3 -0
@@ -32,6 +32,9 @@ Makefile.in *.swp /tags +TAGS +/cscope.files +/cscope.out # make check results /test-suite.log
extensions/GNUmakefile.in +64 -2
81 lines not on this page · raw message
Signature · 1 line
2.40.0
Phil Sutter
reviewerQuoted 7 lines · Phil Sutter
Copy necessary bits from generated Makefile.in into the static extensions/GNUmakefile.in so it plays nicely when called.
For some reason, using 'make ctags' creates a top-level tags file which does not include others, so not quite useful. Using 'make tags' instead works, but only after I created an etags-wrapper (calling ctags -e) in my ~/bin. Seems as per design, though.
This one sucks: 'make tags' won't cover headers in include/iptables and include/linux because Makefile.am merely lists the directories in EXTRA_DIST.
Since automake does not support anything involving wildcards, I see only two options moving forward:
A) List the individual files in EXTRA_DIST instead of the directories
B) Replace Makefile.am by (yet another) GNUmakefile.in
While (A) means updating Makefile.am whenever a new linux header is being cached, (B) is going into the false direction in my opinion.
Better ideas are appreciated, of course. :)
Cheers, Phil