Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 251caa5

Browse files
committed
A different solution for Patch #100979: support for out-of-tree "make TAGS"
The version there built the tags and TAGS files in the build directory. I like them in the source directory. The simplest solution is to cd to the source directory before running ctags or etags. Tested both superficially and they work for me, on Linux Red Hat 6.1.
1 parent e39dab6 commit 251caa5

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

Makefile.in

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -460,13 +460,16 @@ autoconf:
460460

461461
# Create a tags file for vi
462462
tags::
463-
ctags -w -t Include/*.h
464-
for i in $(SUBDIRS); do ctags -w -t -a $$i/*.[ch]; done
463+
cd $(srcdir); \
464+
ctags -w -t Include/*.h; \
465+
for i in $(SUBDIRS); do ctags -w -t -a $$i/*.[ch]; \
466+
done; \
465467
sort tags -o tags
466468

467469
# Create a tags file for GNU Emacs
468470
TAGS::
469-
etags Include/*.h
471+
cd $(srcdir); \
472+
etags Include/*.h; \
470473
for i in $(SUBDIRS); do etags -a $$i/*.[ch]; done
471474

472475
# Add dependencies to sub-Makefiles

0 commit comments

Comments
 (0)