Tue Aug 18 17:21:51 2009 UTC ()
Make the 'tags' target work by borrowing stuff from sys/arch/i386/Makefile.


(dyoung)
diff -r1.7 -r1.8 src/sys/arch/xen/Makefile

cvs diff -r1.7 -r1.8 src/sys/arch/xen/Makefile (expand / switch to unified diff)

--- src/sys/arch/xen/Makefile 2009/05/20 03:41:25 1.7
+++ src/sys/arch/xen/Makefile 2009/08/18 17:21:51 1.8
@@ -1,41 +1,44 @@ @@ -1,41 +1,44 @@
1# $NetBSD: Makefile,v 1.7 2009/05/20 03:41:25 dyoung Exp $ 1# $NetBSD: Makefile,v 1.8 2009/08/18 17:21:51 dyoung Exp $
2 2
3.include <bsd.own.mk> 3.include <bsd.own.mk>
4 4
5# Makefile for xen tags file 5# Makefile for xen tags file
6 6
7.include "../../kern/Make.tags.inc" 7.include "../../kern/Make.tags.inc"
8 8
9.ifmake tags 9.ifmake tags
10.include "${SYSDIR}/arch/xen/conf/Makefile.arch.inc" 10.include "${SYSDIR}/arch/xen/conf/Makefile.arch.inc"
11.endif 11.endif
12 12
13TXEN= ${SYSDIR}/arch/xen/tags 13TXEN= ${SYSDIR}/arch/xen/tags
14 14
15SXEN!= ${TOOL_AWK} '($$2 ~ /^arch.*\.[c]$$/) {print "${SYSDIR}/" $$2}' \ 15SXEN!= ${TOOL_AWK} '/^\#/ { next } ($$2 ~ /^arch.*\.[c]$$/) {print "${SYSDIR}/" $$2}' \
16 ${SYSDIR}/arch/xen/conf/files.xen 16 ${SYSDIR}/arch/xen/conf/files.xen
17AXEN!= ${TOOL_AWK} '($$2 ~ /^arch.*\.[sS]$$/) {print "${SYSDIR}/" $$2}' \ 17SXEN+= ${SYSDIR}/arch/xen/include/*.h
 18SXEN+= ${SYSDIR}/arch/xen/include/*/*.h
 19SXEN+= ${SYSDIR}/arch/xen/include/*/*/*.h
 20AXEN!= ${TOOL_AWK} '/^\#/ { next } ($$2 ~ /^arch.*\.[sS]$$/) {print "${SYSDIR}/" $$2}' \
18 ${SYSDIR}/arch/xen/conf/files.xen 21 ${SYSDIR}/arch/xen/conf/files.xen
19AXEN+= ${SYSDIR}/arch/xen/${XEN_BUILD}/*.[sS] 22AXEN+= ${SYSDIR}/arch/xen/${XEN_BUILD}/*.[sS]
20 23
21# Directories in which to place tags links 24# Directories in which to place tags links
22DXEN= xen ${XEN_MACHINE_ARCHS} include 25DXEN= xen ${XEN_MACHINE_ARCHS} include
23 26
24tags: 27tags:
25 -rm -f ${TXEN} 28 -rm -f ${TXEN}
26 -echo ${SXEN} | xargs ctags -wadtf ${TXEN} 29 -echo ${SXEN} | xargs ctags -wadtf ${TXEN}
27 ${FINDCOMM} | xargs ctags -wadtf ${TXEN} 30 ${FINDCOMM} | xargs ctags -wadtf ${TXEN}
28 egrep "^ENTRY(.*)|^ALTENTRY(.*)" ${AXEN} | \ 31 egrep "^ENTRY(.*)|^ALTENTRY(.*)" ${AXEN} | \
29 ${TOOL_SED} -e \ 32 ${TOOL_SED} -e \
30 "s;\([^:]*\):\([^(]*\)(\([^, )]*\)\(.*\);\3 \1 /^\2(\3\4$$/;" \ 33 "s;\([^:]*\):\([^(]*\)(\([^, )]*\)\(.*\);\3 \1 /^\2(\3\4$$/;" \
31 >> ${TXEN} 34 >> ${TXEN}
32 sort -o ${TXEN} ${TXEN} 35 sort -o ${TXEN} ${TXEN}
33 36
34links: 37links:
35 -for i in ${DXEN}; do \ 38 -for i in ${DXEN}; do \
36 (cd $$i && rm -f tags; ln -s ../tags tags); done 39 (cd $$i && rm -f tags; ln -s ../tags tags); done
37 40
38 41
39SUBDIR= compile include 42SUBDIR= compile include
40 43
41.include <bsd.subdir.mk> 44.include <bsd.subdir.mk>