summaryrefslogtreecommitdiffstats
path: root/share/mk
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2010-01-21 13:15:14 +0000
committerru <ru@FreeBSD.org>2010-01-21 13:15:14 +0000
commit7e3f6b423a60b2b27c88b2be211964b06cc7ca67 (patch)
tree77278bc35c0315516b6691b7bd0a0c02a2357c7a /share/mk
parent83546818a88bc4ee8af8f6cbfcc664e99083c415 (diff)
downloadFreeBSD-src-7e3f6b423a60b2b27c88b2be211964b06cc7ca67.zip
FreeBSD-src-7e3f6b423a60b2b27c88b2be211964b06cc7ca67.tar.gz
MFC r202578 and r202579:
If CTAGS is not set or set to something other than "ctags" or "gtags", "cleandepend" was not removing the .depend file; fixed. [1] Allow the CTAGS to be set to something other than "gtags" or "ctags", but assume it supports a ctags(1)-compatible syntax. [2] PR: 126747 [1], 46676 [2]
Diffstat (limited to 'share/mk')
-rw-r--r--share/mk/bsd.dep.mk14
1 files changed, 7 insertions, 7 deletions
diff --git a/share/mk/bsd.dep.mk b/share/mk/bsd.dep.mk
index cdcadb0..7711d80 100644
--- a/share/mk/bsd.dep.mk
+++ b/share/mk/bsd.dep.mk
@@ -58,14 +58,14 @@ DEPENDFILE?= .depend
# Keep `tags' here, before SRCS are mangled below for `depend'.
.if !target(tags) && defined(SRCS) && !defined(NO_TAGS)
tags: ${SRCS}
-.if ${CTAGS:T} == "ctags"
- @${CTAGS} ${CTAGSFLAGS} -f /dev/stdout \
- ${.ALLSRC:N*.h} | sed "s;${.CURDIR}/;;" > ${.TARGET}
-.elif ${CTAGS:T} == "gtags"
+.if ${CTAGS:T} == "gtags"
@cd ${.CURDIR} && ${CTAGS} ${GTAGSFLAGS} ${.OBJDIR}
.if defined(HTML)
@cd ${.CURDIR} && htags ${HTAGSFLAGS} -d ${.OBJDIR} ${.OBJDIR}
.endif
+.else
+ @${CTAGS} ${CTAGSFLAGS} -f /dev/stdout \
+ ${.ALLSRC:N*.h} | sed "s;${.CURDIR}/;;" > ${.TARGET}
.endif
.endif
@@ -175,13 +175,13 @@ afterdepend:
.if !target(cleandepend)
cleandepend:
.if defined(SRCS)
-.if ${CTAGS:T} == "ctags"
- rm -f ${DEPENDFILE} tags
-.elif ${CTAGS:T} == "gtags"
+.if ${CTAGS:T} == "gtags"
rm -f ${DEPENDFILE} GPATH GRTAGS GSYMS GTAGS
.if defined(HTML)
rm -rf HTML
.endif
+.else
+ rm -f ${DEPENDFILE} tags
.endif
.endif
.endif
OpenPOWER on IntegriCloud